weaver-work-cli 0.1.40 → 0.1.44
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +17 -0
- package/dist/chunks/{archive-JHTONRST.js → archive-P6TBQGKL.js} +13 -5
- package/dist/chunks/{archive-oa-FCHLCPHC.js → archive-oa-7TQ2NXOH.js} +12 -5
- package/dist/chunks/{asset-RLIHC7DB.js → asset-3ELRG37G.js} +11 -4
- package/dist/chunks/{asset-idle-KVOFTLCP.js → asset-idle-WIGMUFMD.js} +7 -3
- package/dist/chunks/{attachment-content-RZYDB3MB.js → attachment-content-E3276UOV.js} +5 -4
- package/dist/chunks/{blog-42OZTJNP.js → blog-C5NMZAAC.js} +11 -4
- package/dist/chunks/{caizhilian-KRK547K5.js → caizhilian-5XSM2DFP.js} +13 -6
- package/dist/chunks/{calendar-RTWAMKHD.js → calendar-FI2WNSBO.js} +71 -26
- package/dist/chunks/{chunk-CXRQWOZ5.js → chunk-3YBDYOC4.js} +3 -3
- package/dist/chunks/{chunk-OOUTBLZ4.js → chunk-56EZERK4.js} +1 -1
- package/dist/chunks/chunk-6N4JPNFL.js +76 -0
- package/dist/chunks/{chunk-ZUX3P6BQ.js → chunk-727FH2NI.js} +1 -1
- package/dist/chunks/chunk-7BDPM5ST.js +11 -0
- package/dist/chunks/{chunk-LN447PY2.js → chunk-BCVYBYYT.js} +432 -2247
- package/dist/chunks/{chunk-7E6MUOEK.js → chunk-CWYGFU5B.js} +2 -2
- package/dist/chunks/{chunk-NOODWMCL.js → chunk-D4ADSZ7H.js} +1 -1
- package/dist/chunks/{chunk-WFFNM65B.js → chunk-ETNJSKMM.js} +281 -29
- package/dist/chunks/{chunk-CAQNBBQA.js → chunk-F4E4EM35.js} +3 -3
- package/dist/chunks/{chunk-4CTESSKI.js → chunk-FAZTGX7S.js} +6 -6
- package/dist/chunks/chunk-FRZKBMSW.js +2562 -0
- package/dist/chunks/{chunk-BYBSCN4X.js → chunk-G7PQWD4L.js} +6 -3
- package/dist/chunks/{chunk-NJKREDA3.js → chunk-GAMZLAG2.js} +1 -1
- package/dist/chunks/{chunk-FLS4DPGP.js → chunk-GM6J7Q4B.js} +28 -15
- package/dist/chunks/{chunk-NETCCARD.js → chunk-GRDRG6HP.js} +3 -3
- package/dist/chunks/chunk-HIT4Y6OI.js +1238 -0
- package/dist/chunks/{chunk-EZALDOQH.js → chunk-HP7JIYMT.js} +5 -2
- package/dist/chunks/{chunk-IZSSVYAG.js → chunk-IAZ3UPY6.js} +3 -3
- package/dist/chunks/{chunk-ZEDWSH32.js → chunk-IC62NFM5.js} +1 -1
- package/dist/chunks/{chunk-P26ZWSKU.js → chunk-KIHNAS25.js} +5 -2
- package/dist/chunks/{chunk-57IECMWX.js → chunk-N4M2DDFE.js} +29 -15
- package/dist/chunks/{chunk-JWRZM2H2.js → chunk-OF4S23UB.js} +4 -4
- package/dist/chunks/{chunk-VNBU55SL.js → chunk-PC7VKEB5.js} +80 -2458
- package/dist/chunks/{chunk-G2JSIUWF.js → chunk-PUQS5MWL.js} +91 -2
- package/dist/chunks/{chunk-E7OK5WD5.js → chunk-Q4OYAQYH.js} +5 -5
- package/dist/chunks/{chunk-7BRU4EFH.js → chunk-QVSWRLLU.js} +35 -6
- package/dist/chunks/{chunk-T6EGVBKU.js → chunk-TA7FXXJD.js} +6 -3
- package/dist/chunks/{chunk-GPMFD4RD.js → chunk-TXUG266F.js} +1 -1
- package/dist/chunks/{chunk-4TEDNCON.js → chunk-UFIT2UU3.js} +354 -56
- package/dist/chunks/{chunk-LUSPKZKY.js → chunk-UG5G54VL.js} +1 -0
- package/dist/chunks/{chunk-NIAJ5ZCG.js → chunk-UL5XUQ25.js} +5 -2
- package/dist/chunks/{chunk-FMPJJYYI.js → chunk-WRXSAVKO.js} +1 -1
- package/dist/chunks/{chunk-7U577Q7U.js → chunk-WSF4NNMR.js} +3 -3
- package/dist/chunks/chunk-XHK4MDR5.js +2497 -0
- package/dist/chunks/{chunk-LFMSDBZN.js → chunk-XNIK66I4.js} +326 -161
- package/dist/chunks/{chunk-3SO6QL6U.js → chunk-YWX377BY.js} +5 -2
- package/dist/chunks/{chunk-BYATLLEF.js → chunk-Z3GDFVJR.js} +1 -1
- package/dist/chunks/{chunk-I566ZYNF.js → chunk-Z7VYWPZV.js} +1 -1
- package/dist/chunks/{conflict-VR55AOOO.js → conflict-ARLSZJ6V.js} +4 -3
- package/dist/chunks/{continuation-2CKSBLA6.js → continuation-3S37AUSH.js} +4 -3
- package/dist/chunks/{continuation-RN6PZN2M.js → continuation-3XLYYTKV.js} +4 -3
- package/dist/chunks/{continuation-HZIZRZBX.js → continuation-HFW2YT5S.js} +4 -3
- package/dist/chunks/{continuation-NLECEJPX.js → continuation-KI7DRRZN.js} +4 -3
- package/dist/chunks/{contract-HI4FNPYE.js → contract-DNIIW5VJ.js} +13 -5
- package/dist/chunks/{cowork-HJLI353D.js → cowork-GMLRGVIW.js} +31 -14
- package/dist/chunks/create-flow-J22BO65E.js +56 -0
- package/dist/chunks/{ebuilder-form-HTGI63UU.js → ebuilder-form-ANV2FHYV.js} +12 -7
- package/dist/chunks/{ehr-GYXIYH3A.js → ehr-GSTGAIY3.js} +695 -1255
- package/dist/chunks/{employee-SAK2QYXX.js → employee-22BGJ3QS.js} +3 -3
- package/dist/chunks/{env-DW3G4HUO.js → env-BX3VRFS7.js} +4 -3
- package/dist/chunks/{esb-I5INCEFE.js → esb-ATAIASX2.js} +12 -7
- package/dist/chunks/{factory-TKXGXS6L.js → factory-PETTFME6.js} +3 -2
- package/dist/chunks/{fna-K2MHTQ24.js → fna-YEKBSFSX.js} +14 -8
- package/dist/chunks/{group-chat-VYBNMJLG.js → group-chat-BFVXAYFX.js} +7 -4
- package/dist/chunks/{host-D5SERMAJ.js → host-HRBXEPDQ.js} +5 -5
- package/dist/chunks/{host-JM4YVHFM.js → host-LR55CTHP.js} +5 -5
- package/dist/chunks/{host-L3VLITMT.js → host-SUOY6VYQ.js} +5 -5
- package/dist/chunks/{host-ZUQTJYYK.js → host-SZGV4UNT.js} +5 -5
- package/dist/chunks/{host-256GVCAH.js → host-WIKN2EJ5.js} +5 -5
- package/dist/chunks/{hrm-VLRBKTZB.js → hrm-NRDO4W5G.js} +11 -7
- package/dist/chunks/{im-QK3VTLXK.js → im-IQ2HN23S.js} +11 -10
- package/dist/chunks/{invoice-T5JTA32H.js → invoice-MNRW76PP.js} +636 -1768
- package/dist/chunks/{jiuchuanhui-P2FNEQVZ.js → jiuchuanhui-DTRBAX4N.js} +14 -6
- package/dist/chunks/{lazy-dispatch-XRRI46M6.js → lazy-dispatch-ZVWAI25B.js} +7 -6
- package/dist/chunks/{mail-3Y7MJ6PS.js → mail-ZVAUXOJA.js} +16 -14
- package/dist/chunks/{meeting-M7LTXGJE.js → meeting-FEVPZ67S.js} +21 -13
- package/dist/chunks/{okr-OBC6S67L.js → okr-SDH3E5RA.js} +12 -5
- package/dist/chunks/{operations-5QL3AECO.js → operations-62N6EP3C.js} +4 -3
- package/dist/chunks/{plan-5H6I53SK.js → plan-E35JFDI7.js} +12 -5
- package/dist/chunks/{project-L75QZV4S.js → project-73QXBAB2.js} +49 -25
- package/dist/chunks/reception-UWZVACBN.js +1899 -0
- package/dist/chunks/recruit-stage-4MAOCKFY.js +4770 -0
- package/dist/chunks/registry-IM5G23LS.js +24 -0
- package/dist/chunks/{registry-UGRBCBHO.js → registry-JDUS4E7D.js} +7 -6
- package/dist/chunks/{registry-RXPN6BBT.js → registry-KNKSCJNT.js} +7 -6
- package/dist/chunks/{registry-NYPYMZXG.js → registry-PO7SI256.js} +4 -4
- package/dist/chunks/{registry-QGHFNUWS.js → registry-PVUZQDDQ.js} +3 -3
- package/dist/chunks/{room-recommend-A3UDC3CA.js → room-recommend-H7KLXA5R.js} +6 -5
- package/dist/chunks/{schedule-5GCACCK7.js → schedule-ESZIBAUO.js} +6 -5
- package/dist/chunks/{workflow-M5ZJ7DWF.js → workflow-CWJFJLQU.js} +15 -10
- package/dist/cmd/action.js +6 -0
- package/dist/cmd/identity/index.js +45 -0
- package/dist/cmd/index.js +2 -0
- package/dist/core/continuation-ttl.js +18 -0
- package/dist/core/error-codes.js +85 -0
- package/dist/core/logger.js +11 -0
- package/dist/index.js +41 -30
- package/dist/internal/e10/auth/commands.js +164 -8
- package/dist/internal/e10/auth/error-log.js +182 -0
- package/dist/internal/e10/auth/messages.js +6 -0
- package/dist/internal/e10/auth/session.js +34 -3
- package/dist/internal/e10/auth/xiaoe.js +286 -44
- package/dist/internal/e10/auth-recovery.js +72 -14
- package/dist/internal/e10/context.js +72 -13
- package/dist/internal/e10/index.js +1 -1
- package/dist/internal/e10/network-error.js +93 -0
- package/dist/internal/e10/request-runtime.js +6 -0
- package/dist/internal/skills/install.js +9 -1
- package/dist/shortcuts/archive/continuation.js +2 -1
- package/dist/shortcuts/archive/index.js +3 -0
- package/dist/shortcuts/archive/operations/confirm.js +2 -1
- package/dist/shortcuts/archive-oa/continuation.js +2 -1
- package/dist/shortcuts/archive-oa/index.js +2 -0
- package/dist/shortcuts/archive-oa/operations/confirm.js +2 -1
- package/dist/shortcuts/asset/continuation.js +2 -1
- package/dist/shortcuts/asset/index.js +2 -0
- package/dist/shortcuts/asset-idle/index.js +2 -0
- package/dist/shortcuts/blog/continuation.js +2 -1
- package/dist/shortcuts/blog/index.js +2 -0
- package/dist/shortcuts/caizhilian/continuation.js +2 -1
- package/dist/shortcuts/caizhilian/index.js +2 -0
- package/dist/shortcuts/caizhilian/operations/confirm.js +3 -2
- package/dist/shortcuts/calendar/continuation.js +2 -1
- package/dist/shortcuts/calendar/index.js +2 -0
- package/dist/shortcuts/calendar/operations/read.js +31 -22
- package/dist/shortcuts/calendar/operations/write.js +46 -2
- package/dist/shortcuts/contract/continuation.js +2 -1
- package/dist/shortcuts/contract/index.js +2 -0
- package/dist/shortcuts/contract/operations/write.js +2 -1
- package/dist/shortcuts/cowork/continuation.js +2 -1
- package/dist/shortcuts/cowork/index.js +2 -0
- package/dist/shortcuts/cowork/operations/discuss-write.js +5 -1
- package/dist/shortcuts/cowork/operations/item-write.js +1 -7
- package/dist/shortcuts/cowork/operations/member-write.js +3 -1
- package/dist/shortcuts/cowork/operations/permission-write.js +5 -1
- package/dist/shortcuts/cowork/operations/shared.js +7 -0
- package/dist/shortcuts/ebuilder-form/continuation.js +2 -1
- package/dist/shortcuts/ebuilder-form/index.js +2 -0
- package/dist/shortcuts/ebuilder-form/operations/write.js +3 -2
- package/dist/shortcuts/ehr/continuation.js +2 -1
- package/dist/shortcuts/ehr/index.js +2 -0
- package/dist/shortcuts/ehr/operations/attend-write.js +44 -2
- package/dist/shortcuts/ehr/operations/hr-contact.js +7 -4
- package/dist/shortcuts/ehr/operations/hr-report.js +13 -7
- package/dist/shortcuts/ehr/operations/recruit-candidate-import.js +317 -63
- package/dist/shortcuts/ehr/operations/recruit-position.js +134 -2
- package/dist/shortcuts/ehr/operations/recruit-write.js +263 -18
- package/dist/shortcuts/ehr/operations/recruit.js +10 -4
- package/dist/shortcuts/ehr/operations/shared.js +47 -0
- package/dist/shortcuts/esb/continuation.js +2 -1
- package/dist/shortcuts/esb/index.js +2 -0
- package/dist/shortcuts/esb/operations/trigger.js +2 -1
- package/dist/shortcuts/fna/continuation.js +2 -1
- package/dist/shortcuts/fna/index.js +2 -0
- package/dist/shortcuts/fna/operations/invoice-writeoff.js +1 -1
- package/dist/shortcuts/fna/operations/loan.js +1 -1
- package/dist/shortcuts/hrm/index.js +2 -0
- package/dist/shortcuts/hrm/operations/org.js +118 -0
- package/dist/shortcuts/im/continuation.js +2 -1
- package/dist/shortcuts/index.js +10 -0
- package/dist/shortcuts/invoice/continuation.js +2 -1
- package/dist/shortcuts/invoice/index.js +14 -15
- package/dist/shortcuts/invoice/invoice-record.js +93 -0
- package/dist/shortcuts/invoice/manifest.js +190 -393
- package/dist/shortcuts/invoice/operations/add.js +2 -1
- package/dist/shortcuts/invoice/operations/delete.js +2 -1
- package/dist/shortcuts/invoice/operations/import.js +2 -1
- package/dist/shortcuts/invoice/operations/issuing-contract-detail.js +86 -0
- package/dist/shortcuts/invoice/operations/issuing-contracts.js +210 -0
- package/dist/shortcuts/invoice/operations/registry.js +17 -17
- package/dist/shortcuts/invoice/operations/reim-auto.js +4 -569
- package/dist/shortcuts/invoice/operations/reim.js +52 -341
- package/dist/shortcuts/invoice/operations/shared.js +21 -4
- package/dist/shortcuts/invoice/operations/update.js +2 -1
- package/dist/shortcuts/invoice/projection.js +10 -62
- package/dist/shortcuts/jiuchuanhui/continuation.js +2 -1
- package/dist/shortcuts/jiuchuanhui/index.js +2 -0
- package/dist/shortcuts/jiuchuanhui/operations/datajson.js +2 -1
- package/dist/shortcuts/jiuchuanhui/operations/esb.js +2 -1
- package/dist/shortcuts/mail/continuation.js +2 -1
- package/dist/shortcuts/mail/index.js +2 -0
- package/dist/shortcuts/mail/operations/mail-blacklist.js +1 -1
- package/dist/shortcuts/mail/operations/mail-contacts.js +1 -1
- package/dist/shortcuts/mail/operations/mail-send.js +1 -1
- package/dist/shortcuts/mail/operations/mail-sign.js +1 -1
- package/dist/shortcuts/mail/operations/mail-template.js +1 -1
- package/dist/shortcuts/meeting/continuation.js +2 -1
- package/dist/shortcuts/meeting/index.js +2 -0
- package/dist/shortcuts/meeting/operations/change.js +1 -1
- package/dist/shortcuts/meeting/operations/create.js +1 -1
- package/dist/shortcuts/meeting/operations/eb/catalog.js +4 -1
- package/dist/shortcuts/meeting/operations/eb/create-flow.js +101 -35
- package/dist/shortcuts/meeting/operations/eb/decision.js +1 -1
- package/dist/shortcuts/meeting/operations/eb/factory.js +34 -1
- package/dist/shortcuts/meeting/operations/eb/group-chat.js +25 -3
- package/dist/shortcuts/meeting/operations/eb/person-cache.js +96 -0
- package/dist/shortcuts/meeting/operations/eb/room-recommend.js +33 -11
- package/dist/shortcuts/meeting/operations/lifecycle.js +1 -1
- package/dist/shortcuts/meeting/operations/receipts.js +1 -1
- package/dist/shortcuts/meeting/operations/signs.js +1 -1
- package/dist/shortcuts/okr/continuation.js +2 -1
- package/dist/shortcuts/okr/index.js +2 -0
- package/dist/shortcuts/okr/operations/write.js +1 -1
- package/dist/shortcuts/plan/continuation.js +2 -1
- package/dist/shortcuts/plan/index.js +2 -0
- package/dist/shortcuts/plan/operations/write.js +1 -1
- package/dist/shortcuts/project/continuation.js +2 -1
- package/dist/shortcuts/project/index.js +2 -0
- package/dist/shortcuts/project/operations/read.js +6 -25
- package/dist/shortcuts/project/operations/shared.js +22 -0
- package/dist/shortcuts/project/operations/write.js +28 -2
- package/dist/shortcuts/reception/constants.js +53 -0
- package/dist/shortcuts/reception/errors.js +54 -0
- package/dist/shortcuts/reception/host.js +125 -0
- package/dist/shortcuts/reception/index.js +198 -0
- package/dist/shortcuts/reception/manifest.js +177 -0
- package/dist/shortcuts/reception/operations/ask.js +71 -0
- package/dist/shortcuts/reception/operations/browsertool.js +58 -0
- package/dist/shortcuts/reception/operations/compose.js +129 -0
- package/dist/shortcuts/reception/operations/customparams.js +74 -0
- package/dist/shortcuts/reception/operations/doc.js +238 -0
- package/dist/shortcuts/reception/operations/docrender.js +36 -0
- package/dist/shortcuts/reception/operations/panels.js +179 -0
- package/dist/shortcuts/reception/operations/registry.js +26 -0
- package/dist/shortcuts/reception/operations/render-assets.js +184 -0
- package/dist/shortcuts/reception/operations/render.js +123 -0
- package/dist/shortcuts/reception/operations/runs.js +38 -0
- package/dist/shortcuts/reception/operations/schedule.js +127 -0
- package/dist/shortcuts/reception/operations/shared.js +196 -0
- package/dist/shortcuts/reception/operations/snapshot.js +68 -0
- package/dist/shortcuts/reception/operations/types.js +1 -0
- package/dist/shortcuts/reception/operations.js +33 -0
- package/dist/shortcuts/reception/upload.js +218 -0
- package/dist/shortcuts/recruit-stage/context.js +231 -0
- package/dist/shortcuts/recruit-stage/continuation.js +74 -0
- package/dist/shortcuts/recruit-stage/errors.js +65 -0
- package/dist/shortcuts/recruit-stage/host.js +109 -0
- package/dist/shortcuts/recruit-stage/index.js +115 -0
- package/dist/shortcuts/recruit-stage/manifest.js +29 -0
- package/dist/shortcuts/recruit-stage/operations/interview-arrange.js +722 -0
- package/dist/shortcuts/recruit-stage/operations/interview-feedback.js +269 -0
- package/dist/shortcuts/recruit-stage/operations/jd-create.js +719 -0
- package/dist/shortcuts/recruit-stage/operations/list.js +431 -0
- package/dist/shortcuts/recruit-stage/operations/registry.js +38 -0
- package/dist/shortcuts/recruit-stage/operations/resume-import.js +1354 -0
- package/dist/shortcuts/recruit-stage/operations/search.js +158 -0
- package/dist/shortcuts/recruit-stage/operations/types.js +25 -0
- package/dist/shortcuts/recruit-stage/school-tiers.json +318 -0
- package/dist/shortcuts/recruit-stage/shared.js +608 -0
- package/dist/shortcuts/workflow/continuation.js +2 -1
- package/dist/shortcuts/workflow/index.js +2 -0
- package/dist/shortcuts/workflow/operations/form.js +32 -8
- package/dist/shortcuts/workflow/operations/todoSmartConvert/detailFieldRules.js +4 -2
- package/dist/shortcuts/workflow/operations/todoSmartConvert/summaryCache.js +13 -6
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoDetailCache.js +17 -24
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoDetailFetcher.js +14 -9
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoSmartConvert.collect.js +50 -8
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoSmartConvert.core.js +2 -1
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoSmartConvert.detail.js +17 -11
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoSmartConvert.group.js +7 -39
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoSmartConvert.groupSummary.js +3 -2
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoSmartConvert.js +51 -15
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoSmartConvert.pipeline.js +16 -1
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoSmartConvert.smartGroup.js +151 -63
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoSmartConvert.subGroup.js +56 -0
- package/dist/shortcuts/workflow/operations/todoSmartConvert/todoSmartConvert.summary.js +39 -14
- package/dist/shortcuts/workflow/operations/write.js +1 -1
- package/docs/_catalog.md +3 -0
- package/docs/agent-invoice.md +1 -1
- package/docs/archive-oa.md +1 -1
- package/docs/caizhilian.md +1 -1
- package/docs/calendar.md +1 -1
- package/docs/contract.md +1 -1
- package/docs/e10-auth.md +23 -1
- package/docs/ehr.md +2 -2
- package/docs/esb.md +1 -1
- package/docs/im.md +1 -1
- package/docs/invoice.md +8 -12
- package/docs/okr.md +1 -1
- package/docs/operation-manual.md +8 -0
- package/docs/reception.md +119 -0
- package/package.json +1 -1
- package/scripts/clean.mjs +43 -2
- package/scripts/install-skill-to-xiaoe.mjs +105 -0
- package/scripts/package-skill.mjs +4 -2
- package/skill-template/business-info.json +42 -2
- package/skill-template/domains/caizhilian.md +1 -1
- package/skill-template/domains/reception-flow.md +18 -0
- package/skill-template/domains/recruit-stage.md +29 -0
- package/skill-template/domains/yepiaotong.md +4 -7
- package/skills/weaver-e10-archive-oa/references/source-manifest.json +14 -14
- package/skills/weaver-e10-blog/references/blog-publish.md +1 -1
- package/skills/weaver-e10-blog/references/source-manifest.json +7 -7
- package/skills/weaver-e10-caizhilian/references/source-manifest.json +21 -21
- package/skills/weaver-e10-caizhilian/references/write-protocol.md +2 -2
- package/skills/weaver-e10-calendar/SKILL.md +2 -1
- package/skills/weaver-e10-calendar/references/calendar-write.md +55 -1
- package/skills/weaver-e10-cowork/SKILL.md +1 -1
- package/skills/weaver-e10-cowork/references/cowork-write.md +3 -1
- package/skills/weaver-e10-ebuilder-form/SKILL.md +1 -1
- package/skills/weaver-e10-ebuilder-form/references/custom-api.md +1 -1
- package/skills/weaver-e10-ebuilder-form/references/openapi-write.md +1 -1
- package/skills/weaver-e10-esb/SKILL.md +2 -2
- package/skills/weaver-e10-esb/references/source-manifest.json +22 -22
- package/skills/weaver-e10-esb/references/trigger.md +2 -2
- package/skills/weaver-e10-jinchengda/references/contract-clause-library-crud.md +1 -1
- package/skills/weaver-e10-jinchengda/references/contract-clause-reference-save.md +1 -1
- package/skills/weaver-e10-jinchengda/references/contract-request-write.md +1 -1
- package/skills/weaver-e10-jinchengda/references/source-manifest.json +29 -29
- package/skills/weaver-e10-jucailin/SKILL.md +1 -1
- package/skills/weaver-e10-jucailin/references/attend-write.md +10 -2
- package/skills/weaver-e10-jucailin/references/hr-contact.md +8 -0
- package/skills/weaver-e10-jucailin/references/hr-report.md +8 -0
- package/skills/weaver-e10-jucailin/references/recruit-create.md +14 -5
- package/skills/weaver-e10-jucailin/references/recruit-read.md +1 -1
- package/skills/weaver-e10-jucailin/references/recruit-write.md +5 -4
- package/skills/weaver-e10-mail/SKILL.md +1 -1
- package/skills/weaver-e10-meeting/SKILL.md +39 -7
- package/skills/weaver-e10-meeting/references/meeting-change.md +1 -1
- package/skills/weaver-e10-meeting/references/meeting-create.md +1 -1
- package/skills/weaver-e10-meeting/references/meeting-lifecycle.md +1 -1
- package/skills/weaver-e10-meeting/references/meeting-verification.md +1 -1
- package/skills/weaver-e10-okr/references/okr-align.md +1 -1
- package/skills/weaver-e10-okr/references/okr-keyresult.md +1 -1
- package/skills/weaver-e10-okr/references/okr-write.md +1 -1
- package/skills/weaver-e10-okr/references/source-manifest.json +8 -8
- package/skills/weaver-e10-plan/references/plan-report-write.md +1 -1
- package/skills/weaver-e10-plan/references/source-manifest.json +20 -20
- package/skills/weaver-e10-qiyecheng/references/loan-management.md +1 -1
- package/skills/weaver-e10-qiyecheng/references/source-manifest.json +18 -18
- package/skills/weaver-e10-reception-flow/SKILL.md +173 -0
- package/skills/weaver-e10-reception-flow/assets//350/241/214/347/250/213/345/215/225/346/250/241/346/235/277-/346/263/233/345/276/256.docx +0 -0
- package/skills/weaver-e10-reception-flow/data/fields-snapshot.json +213 -0
- package/skills/weaver-e10-reception-flow/references/browsertool.md +68 -0
- package/skills/weaver-e10-reception-flow/references/env-pitfalls.md +51 -0
- package/skills/weaver-e10-reception-flow/references/fields-snapshot.md +227 -0
- package/skills/weaver-e10-reception-flow/references/guide.md +179 -0
- package/skills/weaver-e10-reception-flow/scripts/locate.sh +14 -0
- package/skills/weaver-e10-reception-flow/scripts/render.py +724 -0
- package/skills/weaver-e10-recruit-stage/SKILL.md +230 -0
- package/skills/weaver-e10-recruit-stage/agents/openai.yaml +119 -0
- package/skills/weaver-e10-recruit-stage/lib/recruit-xiaoe-file.mjs +188 -0
- package/skills/weaver-e10-recruit-stage/lib/xiaoe-session.mjs +66 -0
- package/skills/weaver-e10-recruit-stage/references/position-templates.md +202 -0
- package/skills/weaver-e10-recruit-stage/references/recruit-arrange-interview.md +322 -0
- package/skills/weaver-e10-recruit-stage/references/recruit-capability-check.md +127 -0
- package/skills/weaver-e10-recruit-stage/references/recruit-check-install.md +65 -0
- package/skills/weaver-e10-recruit-stage/references/recruit-detail-process.md +63 -0
- package/skills/weaver-e10-recruit-stage/references/recruit-edit-interview-feedback.md +142 -0
- package/skills/weaver-e10-recruit-stage/references/recruit-jd-create.md +95 -0
- package/skills/weaver-e10-recruit-stage/references/recruit-jd-template.md +56 -0
- package/skills/weaver-e10-recruit-stage/references/recruit-list-candidate.md +101 -0
- package/skills/weaver-e10-recruit-stage/references/recruit-list-interview.md +148 -0
- package/skills/weaver-e10-recruit-stage/references/recruit-match-candidates.md +77 -0
- package/skills/weaver-e10-recruit-stage/references/recruit-output-links.md +59 -0
- package/skills/weaver-e10-recruit-stage/references/recruit-resolve-creator.md +69 -0
- package/skills/weaver-e10-recruit-stage/references/recruit-resolve-metadata.md +241 -0
- package/skills/weaver-e10-recruit-stage/references/recruit-resume-import.md +451 -0
- package/skills/weaver-e10-recruit-stage/references/recruit-resume-parse.md +128 -0
- package/skills/weaver-e10-recruit-stage/references/recruit-search-candidate.md +146 -0
- package/skills/weaver-e10-recruit-stage/references/recruit-urge-feedback.md +69 -0
- package/skills/weaver-e10-shared/SKILL.md +1 -1
- package/skills/weaver-e10-shared/references/e10-auth-and-session.md +10 -2
- package/skills/weaver-e10-shijingran/SKILL.md +7 -6
- package/skills/weaver-e10-shijingran/references/operations.md +3 -1
- package/skills/weaver-e10-shijingran/references/source-manifest.json +30 -28
- package/skills/weaver-e10-shijingran/references/write-operations.md +2 -0
- package/skills/weaver-e10-skill-maker/references/module-cli-generation.md +2 -0
- package/skills/weaver-e10-wenshuding/references/source-manifest.json +3 -3
- package/skills/weaver-e10-workflow/SKILL.md +4 -2
- package/skills/weaver-e10-workflow/aigroup/default.json +11 -9
- package/skills/weaver-e10-workflow/references/source-manifest.json +32 -32
- package/skills/weaver-e10-workflow/references/todo-smart-convert.md +23 -13
- package/skills/weaver-e10-workflow/tools/todo-summary.cjs +62 -20
- package/skills/weaver-e10-yepiaotong/SKILL.md +28 -36
- package/skills/weaver-e10-yepiaotong/references/invoice-agent-entry.md +6 -3
- package/skills/weaver-e10-yepiaotong/references/invoice-detail.md +13 -10
- package/skills/weaver-e10-yepiaotong/references/invoice-enterprise-list.md +2 -0
- package/skills/weaver-e10-yepiaotong/references/invoice-issuing-workflow.md +194 -155
- package/skills/weaver-e10-yepiaotong/references/invoice-output-view.md +28 -32
- package/skills/weaver-e10-yepiaotong/references/invoice-personal-list.md +5 -1
- package/skills/weaver-e10-yepiaotong/references/invoice-reim.md +8 -10
- package/skills/weaver-e10-yepiaotong/references/reim-api-reference.md +211 -616
- package/skills/weaver-e10-yepiaotong/references/reim-examples.md +149 -117
- package/skills/weaver-e10-yepiaotong/references/reim-expense-subject-rules.md +17 -20
- package/skills/weaver-e10-yepiaotong/references/reim-form-fill-rules.md +20 -39
- package/skills/weaver-e10-yepiaotong/references/reim-matching-rules.md +55 -22
- package/skills/weaver-e10-yepiaotong/references/reim-phone-subsidy-rules.md +7 -17
- package/skills/weaver-e10-yepiaotong/references/reim-workflow.md +88 -92
- package/skills/weaver-e10-yepiaotong/references/source-manifest.json +144 -354
- package/skills/weaver-e10-yimiaoban/SKILL.md +1 -1
- package/skills/weaver-e10-yimiaoban/references/msg-write.md +1 -1
- package/skills/weaver-e10-yimiaoban/references/safety-boundaries.md +1 -1
- package/skills/weaver-e10-yimiaoban/references/source-manifest.json +7 -7
- package/dist/chunks/chunk-SPRHHSVC.js +0 -465
- package/dist/chunks/registry-KMHCPAAD.js +0 -22
- package/dist/shortcuts/invoice/markdown.js +0 -172
- package/dist/shortcuts/invoice/operations/issuing-qys.js +0 -424
- package/skills/weaver-e10-meeting.zip +0 -0
- package/skills/weaver-e10-yepiaotong/references/invoice-issuing-examples.md +0 -131
- package/skills/weaver-e10-yepiaotong/references/invoice-issuing-form-fill-rules.md +0 -179
|
@@ -15,6 +15,7 @@
|
|
|
15
15
|
* createApply 合并而来):模型只需「取表单 → 填字段 → createRequest」,不必自己判断必填是否缺失
|
|
16
16
|
* ——必填判定完全在 CLI 内部按实际所填数据(含联动带出值)实时计算。
|
|
17
17
|
*/
|
|
18
|
+
import { CONTINUATION_TTL_MS } from '../../../core/continuation-ttl.js';
|
|
18
19
|
import { randomUUID } from 'node:crypto';
|
|
19
20
|
import { workflowSuccess, schemaOf, SCHEMA_REQUEST_ID, SCHEMA_CONTINUATION, SCHEMA_CONFIRM, } from './types.js';
|
|
20
21
|
import { asBool, responseData, toArray, withLeadingMeta, stdoutBytesOf, stdoutCharsOf, STDOUT_SAFE_BYTES, parseNameWithId, resolveMemoryAppId, } from './shared.js';
|
|
@@ -72,7 +73,6 @@ const SYSTEM_FIELD_KEYS = {
|
|
|
72
73
|
};
|
|
73
74
|
/** 附件大小档位 0-5 对应 1/5/10/20/50/100MB;6/9 取同层 customAttmentSize(已修复 bug)。 */
|
|
74
75
|
const ATTACH_SIZE_LIMIT_STEPS_MB = [1, 5, 10, 20, 50, 100];
|
|
75
|
-
const CONTINUATION_TTL_MS = 10 * 60 * 1000;
|
|
76
76
|
/**
|
|
77
77
|
* 大表单输出保护(通用,不针对任何具体工作流/表单)。
|
|
78
78
|
*
|
|
@@ -4720,6 +4720,7 @@ function linkageResultNotice(linkageDetails, fields, hiddenSubforms, rowHidden,
|
|
|
4720
4720
|
* - `title` 取**工作流名称**;`src` 与两处 `routerProps_*` 的 `initialEntries` 用**工作流 id**;
|
|
4721
4721
|
* `src` 末尾另按 `&<字段id>=<值>` 拼上本次要填的字段(2026-10-30 用户裁定,与下面
|
|
4722
4722
|
* `params.customParams` 同一份数据);
|
|
4723
|
+
* `src` 里的 `#` **一律写成 `%23`**(2026-11-05 用户裁定,见 `xiaoEEncodeSrcHash`);
|
|
4723
4724
|
* `params.customParams` 取 `createRequest` **入参**经解析后的字段值(不含表单默认值、不含联动带出的值),
|
|
4724
4725
|
* 同段 `fieldAssignKeys` 列出这次要填的**全部字段 id**(`,` 连接)。
|
|
4725
4726
|
*/
|
|
@@ -4761,6 +4762,11 @@ const XIAOE_INITIAL_VALUES_ROW_SEPARATOR = ';';
|
|
|
4761
4762
|
* 明细多行同口径:`##<id>;<名称>`。
|
|
4762
4763
|
*/
|
|
4763
4764
|
const XIAOE_BROWSER_ID_PREFIX = '##';
|
|
4765
|
+
/**
|
|
4766
|
+
* 交给浏览器页面时带的自定义标识(`src` 与 `params.customParams` 各带一份,值都是 `1`):
|
|
4767
|
+
* 页面据此按「带初始值打开新建页」处理。
|
|
4768
|
+
*/
|
|
4769
|
+
const XIAOE_INITIAL_COVERT_NAME = 1;
|
|
4764
4770
|
/** 单个标量 → URL 传参里的那一段文本。对象按「id 优先」取标识(附件取到的就是 fileid)。 */
|
|
4765
4771
|
function xiaoEUrlParamScalar(value, prefixBrowserId = false) {
|
|
4766
4772
|
if (value === null || value === undefined)
|
|
@@ -4904,9 +4910,10 @@ function xiaoECustomParams(preview, fields) {
|
|
|
4904
4910
|
* `src` 末尾的字段参数(2026-10-30 用户裁定):`&<字段id>=<值>`,与 `params.customParams` 里那份
|
|
4905
4911
|
* 字段值**同一份数据、同一顺序**(`fieldAssignKeys` 是元信息,不进 URL)。
|
|
4906
4912
|
*
|
|
4907
|
-
*
|
|
4908
|
-
*
|
|
4909
|
-
*
|
|
4913
|
+
* 值在这里**原样拼**(不逐个做百分号编码):中文、空格、`,` / `;` 等都保持字面值,与
|
|
4914
|
+
* `params.customParams` 里那份一致。**只有 `#` 例外**——整段 `src` 拼完之后统一换成 `%23`
|
|
4915
|
+
* (见下面的 `xiaoEEncodeSrcHash`,2026-11-05 用户裁定)。唯一剩余代价是值本身含 `&` 时会截断
|
|
4916
|
+
* ——按用户口径以此为准,不在此处兜底改写。
|
|
4910
4917
|
*/
|
|
4911
4918
|
function xiaoESrcFieldQuery(params) {
|
|
4912
4919
|
let query = '';
|
|
@@ -4918,13 +4925,28 @@ function xiaoESrcFieldQuery(params) {
|
|
|
4918
4925
|
}
|
|
4919
4926
|
return query;
|
|
4920
4927
|
}
|
|
4928
|
+
/**
|
|
4929
|
+
* `src` 里的 `#` 一律写成 `%23`(2026-11-05 用户裁定)。
|
|
4930
|
+
*
|
|
4931
|
+
* 原因:`#` 在 URL 里是**片段起始符**,一旦出现在 query 段,浏览器与路由会把 `#` 之后的全部内容
|
|
4932
|
+
* 当成 hash 丢掉 —— 浏览按钮字段的 `##<id>` 前缀(见 `XIAOE_BROWSER_ID_PREFIX`)与用户自己填的
|
|
4933
|
+
* `#` 都会踩这个坑。
|
|
4934
|
+
*
|
|
4935
|
+
* 只作用于 `src` 这一个属性;`params.customParams` 里仍是原样的 `##<id>`(两处不再逐字相同,
|
|
4936
|
+
* 页面解析 `src` 时按 URL 语义还原即可)。
|
|
4937
|
+
*/
|
|
4938
|
+
function xiaoEEncodeSrcHash(src) {
|
|
4939
|
+
return src.replace(/#/gu, '%23');
|
|
4940
|
+
}
|
|
4921
4941
|
/**
|
|
4922
4942
|
* 渲染 `<browsertool>` 块(该块**整体**就是小e 环境下 `createRequest` 的 `finalMarkdown`)。
|
|
4923
4943
|
*
|
|
4924
4944
|
* 除 `title` / `src` / 两处 `routerProps_*` 的 `initialEntries` / `params.customParams` 外全部写死。
|
|
4925
4945
|
*
|
|
4926
|
-
* `src` 形如 `…/flowpage/create/<workflowId>?workflowId=<workflowId>&isCreate=1&<字段id>=<值>&…`
|
|
4927
|
-
* —— 末尾的字段参数与 `params.customParams` 同源(2026-10-30
|
|
4946
|
+
* `src` 形如 `…/flowpage/create/<workflowId>?workflowId=<workflowId>&isCreate=1&initialCovertName=1&<字段id>=<值>&…`
|
|
4947
|
+
* —— 末尾的字段参数与 `params.customParams` 同源(2026-10-30 用户裁定);其中 `#` 全部写成 `%23`
|
|
4948
|
+
* (2026-11-05 用户裁定)。
|
|
4949
|
+
* `initialCovertName=1` 是自定义标识,`params.customParams.initialCovertName: 1` 与之同步(两处都要有)。
|
|
4928
4950
|
*/
|
|
4929
4951
|
function renderXiaoEFillFormMarkdown(params) {
|
|
4930
4952
|
const base = String(params.baseUrl ?? '').replace(/\/+$/u, '');
|
|
@@ -4937,7 +4959,8 @@ function renderXiaoEFillFormMarkdown(params) {
|
|
|
4937
4959
|
arguments: {
|
|
4938
4960
|
type: 'e10',
|
|
4939
4961
|
title: String(params.title ?? ''),
|
|
4940
|
-
|
|
4962
|
+
// `#` 一律转义成 `%23`(2026-11-05 用户裁定):`##<id>` 前缀与用户填的 `#` 都会被当成片段起始符。
|
|
4963
|
+
src: xiaoEEncodeSrcHash(`${base}/sp/workflow${createPath}?workflowId=${workflowId}&isCreate=1&initialCovertName=${XIAOE_INITIAL_COVERT_NAME}${xiaoESrcFieldQuery(params.customParams)}`),
|
|
4941
4964
|
sdkOptions: {
|
|
4942
4965
|
compName: XIAOE_FILL_FORM_SDK_OPTIONS.compName,
|
|
4943
4966
|
routerType: XIAOE_FILL_FORM_SDK_OPTIONS.routerType,
|
|
@@ -4947,9 +4970,10 @@ function renderXiaoEFillFormMarkdown(params) {
|
|
|
4947
4970
|
params_mobile: { ...XIAOE_FILL_FORM_SDK_OPTIONS.params_mobile },
|
|
4948
4971
|
params: {
|
|
4949
4972
|
customParams: {
|
|
4950
|
-
// 字段 id → 值(要填写的字段及值),随后是这次要填的**全部字段 id
|
|
4973
|
+
// 字段 id → 值(要填写的字段及值),随后是这次要填的**全部字段 id** 与自定义标识。
|
|
4951
4974
|
...params.customParams.values,
|
|
4952
4975
|
fieldAssignKeys: params.customParams.keys.join(','),
|
|
4976
|
+
initialCovertName: XIAOE_INITIAL_COVERT_NAME,
|
|
4953
4977
|
},
|
|
4954
4978
|
},
|
|
4955
4979
|
},
|
|
@@ -89,14 +89,16 @@ export function pickInternalMessageContentField(fields) {
|
|
|
89
89
|
*
|
|
90
90
|
* `留言内容` 为空 ⇒ 返回空数组:这是「表单没有业务内容」,不是「只有发起人」。
|
|
91
91
|
*/
|
|
92
|
-
export function pickInternalMessageFieldPairs(fields, basicInfo = {}
|
|
92
|
+
export function pickInternalMessageFieldPairs(fields, basicInfo = {},
|
|
93
|
+
/** 兜底发起人(2026-11-03:汇总链路已不再保留 basic,改由列表行的 createrName 传入) */
|
|
94
|
+
fallbackCreatorName) {
|
|
93
95
|
const content = pickInternalMessageContentField(fields);
|
|
94
96
|
const contentValue = String(content?.value ?? '').trim();
|
|
95
97
|
if (!contentValue)
|
|
96
98
|
return [];
|
|
97
99
|
const name = normalizeDetailFieldName(content?.fieldName) || INTERNAL_MESSAGE_CONTENT_LABEL;
|
|
98
100
|
const pairs = [{ fieldName: name, value: contentValue }];
|
|
99
|
-
const creatorName = String(basicInfo.creatorName ?? '').trim();
|
|
101
|
+
const creatorName = String(basicInfo.creatorName ?? fallbackCreatorName ?? '').trim();
|
|
100
102
|
if (creatorName)
|
|
101
103
|
pairs.push({ fieldName: INTERNAL_MESSAGE_INITIATOR_LABEL, value: creatorName });
|
|
102
104
|
const createdAt = String(basicInfo.createdAt ?? '').trim();
|
|
@@ -125,16 +125,20 @@ export function promptTagOf(prompt) {
|
|
|
125
125
|
/**
|
|
126
126
|
* 缓存条目是否与当前口径/素材匹配。
|
|
127
127
|
*
|
|
128
|
-
*
|
|
129
|
-
* - `pk
|
|
128
|
+
* **失效条件:由 `requestSummaryPrompt`(default.json / 用户意图)调整触发**——
|
|
129
|
+
* - `pk`:**严格比对**(2026-11-04 修正)。调用方只要传了 pk,条目缺 pk 或 pk 不等 ⇒ 一律失效重写。
|
|
130
|
+
* 旧口径(`entry.pk !== undefined` 才比对)等于「改 requestSummaryPrompt 对老条目永远不生效」:
|
|
131
|
+
* 条目是用旧口径写的,缺 pk 只能说明「口径未知」,不能证明「口径没变」。
|
|
132
|
+
* 空口径(`pk === ''`)会照常落库,因此「改空 / 改回非空」同样能触发失效,且空口径组不会抖动。
|
|
130
133
|
* - `maxChars`:双方都存在时才比对,且调用方只在用户**显式**传字数时才传入
|
|
131
134
|
* (`summary.ts` 的 `explicitMaxCharsFor`)——规则/默认字数变化不作废历史摘要;
|
|
132
135
|
* 用户显式要求「10 字以内」时仍会重写(2026-10-22 实测踩坑的保护保留);
|
|
133
136
|
* - `dv`:详情素材特征值仍比对——素材升级 / 排除清单调整后旧摘要缺信息(如安全工单缺行号),
|
|
134
|
-
* 不能继续命中;条目缺 dv =
|
|
137
|
+
* 不能继续命中;条目缺 dv = 旧条目,兼容命中(素材侧无法核验,属另一条口径,未随本次收紧)。
|
|
135
138
|
*/
|
|
136
139
|
function entryMatches(entry, maxChars, pk, dv) {
|
|
137
|
-
|
|
140
|
+
// 调用方不传 pk(undefined)= 不做口径判定(保持对旧调用点的兼容);传了就必须逐字符相等。
|
|
141
|
+
if (pk !== undefined && entry.pk !== pk)
|
|
138
142
|
return false;
|
|
139
143
|
if (maxChars !== undefined && entry.maxChars !== undefined && entry.maxChars !== maxChars)
|
|
140
144
|
return false;
|
|
@@ -151,7 +155,9 @@ function normalizeSummaryEntry(raw) {
|
|
|
151
155
|
if (typeof entry.cachedAt !== 'number' || !Number.isFinite(entry.cachedAt))
|
|
152
156
|
return null;
|
|
153
157
|
const maxChars = typeof entry.maxChars === "number" && Number.isFinite(entry.maxChars) ? entry.maxChars : undefined;
|
|
154
|
-
|
|
158
|
+
// 空串是有效口径(该组本来就没配 requestSummaryPrompt):保留下来,
|
|
159
|
+
// 否则「空口径条目」会被当成「缺 pk 的旧条目」,收紧后每次都 miss。
|
|
160
|
+
const pk = typeof entry.pk === 'string' ? entry.pk : undefined;
|
|
155
161
|
const dv = typeof entry.dv === 'string' && entry.dv !== '' ? entry.dv : undefined;
|
|
156
162
|
return {
|
|
157
163
|
summary: entry.summary,
|
|
@@ -236,7 +242,8 @@ export async function openSummaryCache(ctx) {
|
|
|
236
242
|
summary: text,
|
|
237
243
|
cachedAt: Date.now(),
|
|
238
244
|
...(maxChars === undefined ? {} : { maxChars }),
|
|
239
|
-
|
|
245
|
+
// 空串同样落库(见 entryMatches 注释):空口径与「缺 pk」必须能区分开。
|
|
246
|
+
...(pk === undefined ? {} : { pk }),
|
|
240
247
|
...(dv === undefined || dv === '' ? {} : { dv }),
|
|
241
248
|
});
|
|
242
249
|
dirty = true;
|
|
@@ -5,7 +5,7 @@ import { cacheRoots, readCacheFile, writeCacheFile, SUMMARY_CACHE_PRUNE_INTERVAL
|
|
|
5
5
|
* 规则(用户 2026-10-26 定稿;条目格式 2026-10-30 升 v2):
|
|
6
6
|
* - 键:`requestId__lastFeedBackDateTime`(与该条待办的业务时间绑定——流程一动就换键);
|
|
7
7
|
* - 有效期:7 天,与摘要缓存一致;读的时候逻辑过期,超过清理间隔(3 天)时物理剔除;
|
|
8
|
-
* - **条目带格式版本 `v`**:
|
|
8
|
+
* - **条目带格式版本 `v`**:v4(2026-11-03)起素材 = 排除清单过滤后的 formData **+ 仅 workflowName**;
|
|
9
9
|
* 旧格式条目(无 `v`)读取时视为无效,被新条目逐步覆盖;排除清单变化靠 `excludeTag` 失效;
|
|
10
10
|
* - 详情为空的条目**也写**(`fields: []`),否则这类条目每次都要重拉;
|
|
11
11
|
* - 缓存文件缺失 ⇒ 视为从未缓存过,正常走接口。
|
|
@@ -18,29 +18,28 @@ export const DETAIL_CACHE_TTL_MS = SUMMARY_CACHE_TTL_MS;
|
|
|
18
18
|
/** 与摘要缓存一致:清理间隔 3 天。 */
|
|
19
19
|
export const DETAIL_CACHE_PRUNE_INTERVAL_MS = SUMMARY_CACHE_PRUNE_INTERVAL_MS;
|
|
20
20
|
/**
|
|
21
|
-
* 缓存条目格式版本。
|
|
22
|
-
* -
|
|
23
|
-
*
|
|
24
|
-
* -
|
|
25
|
-
*
|
|
21
|
+
* 缓存条目格式版本。
|
|
22
|
+
* - v2(2026-10-30):素材 = 排除清单过滤后的 formData + 全量 basicInfo,新增 `excludeTag`;
|
|
23
|
+
* - v3(2026-11-01):basicInfo 剔除 `requestTitle` / `flowName`;
|
|
24
|
+
* - **v4(2026-11-03,用户定)**:基础信息**只留 `workflowName`**,其余 basic 字段(creatorName /
|
|
25
|
+
* createdAt / currentNode / flowStatus / requestLevel …)既不入缓存也不入素材;
|
|
26
|
+
* `dv` 相应改为**只对 fields 哈希**。v3 及更早条目读取时视为无效、自动重拉。
|
|
26
27
|
*/
|
|
27
|
-
export const DETAIL_CACHE_ENTRY_VERSION =
|
|
28
|
+
export const DETAIL_CACHE_ENTRY_VERSION = 4;
|
|
28
29
|
export function detailCacheKey(requestId, lastFeedBackDateTime) {
|
|
29
30
|
const stamp = String(lastFeedBackDateTime ?? '').trim();
|
|
30
31
|
return `${requestId}__${stamp}`;
|
|
31
32
|
}
|
|
32
33
|
/**
|
|
33
|
-
*
|
|
34
|
-
*
|
|
35
|
-
*
|
|
34
|
+
* 详情素材特征值 `dv`(2026-11-01 根治「素材升级后旧摘要继续命中」):对**清洗后的 fields**
|
|
35
|
+
* 做稳定序列化 + djb2 哈希。任何素材变化——详情管线升级、`excludeOriginFormDataFields` 调整、
|
|
36
|
+
* 字段增减——都会让它改变;摘要缓存条目的 `dv` 与之比对即可自动失效重写。
|
|
37
|
+
* (v4 起 basic 只剩 workflowName 且不进素材,故不再参与哈希。)
|
|
36
38
|
*/
|
|
37
39
|
export function detailMaterialTagOf(entry) {
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
const material = JSON.stringify([
|
|
41
|
-
basicKeys.map((key) => [key, basic[key]]),
|
|
42
|
-
(entry.fields ?? []).map((field) => [field.fieldName, field.value]),
|
|
43
|
-
]);
|
|
40
|
+
// v4 起 basic 只剩 workflowName 且不进素材 ⇒ dv 只对**清洗后的 fields** 哈希;
|
|
41
|
+
// workflowName 的变化不影响摘要内容,故不参与(改由 pk 侧的口径与分组处理)。
|
|
42
|
+
const material = JSON.stringify((entry.fields ?? []).map((field) => [field.fieldName, field.value]));
|
|
44
43
|
let hash = 5381;
|
|
45
44
|
for (let i = 0; i < material.length; i += 1)
|
|
46
45
|
hash = ((hash << 5) + hash + material.charCodeAt(i)) >>> 0;
|
|
@@ -57,13 +56,7 @@ function normalizeEntry(raw) {
|
|
|
57
56
|
return null;
|
|
58
57
|
if (typeof value.excludeTag !== 'string')
|
|
59
58
|
return null;
|
|
60
|
-
const
|
|
61
|
-
if (value.basicInfo && typeof value.basicInfo === 'object') {
|
|
62
|
-
for (const [key, item] of Object.entries(value.basicInfo)) {
|
|
63
|
-
if (typeof item === 'string')
|
|
64
|
-
basicInfo[key] = item;
|
|
65
|
-
}
|
|
66
|
-
}
|
|
59
|
+
const workflowName = typeof value.workflowName === 'string' ? value.workflowName : '';
|
|
67
60
|
const fields = Array.isArray(value.fields)
|
|
68
61
|
? value.fields
|
|
69
62
|
.filter((item) => Boolean(item) && typeof item.fieldName === 'string'
|
|
@@ -73,7 +66,7 @@ function normalizeEntry(raw) {
|
|
|
73
66
|
const metrics = value.metrics && typeof value.metrics === 'object' ? value.metrics : {};
|
|
74
67
|
return {
|
|
75
68
|
v: DETAIL_CACHE_ENTRY_VERSION,
|
|
76
|
-
|
|
69
|
+
workflowName,
|
|
77
70
|
fields,
|
|
78
71
|
metrics,
|
|
79
72
|
excludeTag: value.excludeTag,
|
|
@@ -110,6 +110,12 @@ function isRetryable(error) {
|
|
|
110
110
|
return true;
|
|
111
111
|
return structured?.retryable === true && structured?.type !== 'authentication';
|
|
112
112
|
}
|
|
113
|
+
/** 列表行上的发起人(**只用于内部留言的「发起人」行**,basic 已丢弃后由它兜底)。 */
|
|
114
|
+
function userIdToCreatorName(options, requestId) {
|
|
115
|
+
const name = options.rowMeta?.get(requestId)?.createrName;
|
|
116
|
+
const text = String(name ?? '').trim();
|
|
117
|
+
return text === '' ? undefined : text;
|
|
118
|
+
}
|
|
113
119
|
/**
|
|
114
120
|
* 单条详情取数。后续切换批量接口时,保持本文件对外的批量结果契约即可。
|
|
115
121
|
*/
|
|
@@ -134,15 +140,14 @@ async function fetchOneDetail(env, requestId, userId, options) {
|
|
|
134
140
|
const normalized = normalizeDetailResponse(response);
|
|
135
141
|
const base = (normalized?.basicInfo ?? {});
|
|
136
142
|
const rawFields = Array.isArray(normalized?.formData?.fields) ? normalized.formData.fields : [];
|
|
137
|
-
// ⓪
|
|
138
|
-
//
|
|
139
|
-
|
|
140
|
-
const basicInfo = Object.fromEntries(Object.entries(base).filter(([key]) => key !== 'requestTitle' && key !== 'flowName'));
|
|
143
|
+
// ⓪ 基础信息**只留 workflowName**(2026-11-03 用户定):其余 basic 字段丢弃,不进缓存也不进素材。
|
|
144
|
+
// `requestTitle` / `flowName` 这类标题字段自然也在丢弃之列。
|
|
145
|
+
const workflowName = String(base.workflowName ?? '').trim();
|
|
141
146
|
// ① 分发类字段(`主送` …)**无条件丢弃**:值是几十个部门的收件人清单,对摘要零信息量,
|
|
142
147
|
// 还会撑大喂给模型的上下文。必须在排除清单之前丢(技术卫生,用户不可在 JSON 里恢复)。
|
|
143
148
|
const usableFields = dropDistributionDetailFields(rawFields);
|
|
144
149
|
// ② 内部留言类:只保留 留言内容 / 发起人 / 发起时间(其余是分发元数据,见 `detailFieldRules.ts`)。
|
|
145
|
-
const internalMessage = isInternalMessageDetail(
|
|
150
|
+
const internalMessage = isInternalMessageDetail(workflowName, usableFields.map((field) => field?.fieldName));
|
|
146
151
|
// ③ 字段值只清洗(实体解码 / 富文本残留 / 压缩空白),不在这一步截断。
|
|
147
152
|
const cleanedFields = usableFields.map((field) => ({
|
|
148
153
|
...field,
|
|
@@ -150,10 +155,10 @@ async function fetchOneDetail(env, requestId, userId, options) {
|
|
|
150
155
|
}));
|
|
151
156
|
// ④ 规则排除清单(aigroup JSON `excludeOriginFormDataFields`):按 fieldName 精确匹配剔除,
|
|
152
157
|
// 两侧都过 `normalizeDetailFieldName`,防【】包裹 / 空白等排版差异绕过精确匹配。
|
|
153
|
-
const excludeFields = excludeFieldsFor(
|
|
158
|
+
const excludeFields = excludeFieldsFor(workflowName);
|
|
154
159
|
const excludeSet = new Set(excludeFields.map((name) => normalizeDetailFieldName(name)));
|
|
155
160
|
const picked = (internalMessage
|
|
156
|
-
? pickInternalMessageFieldPairs(cleanedFields,
|
|
161
|
+
? pickInternalMessageFieldPairs(cleanedFields, {}, userIdToCreatorName(options, requestId))
|
|
157
162
|
: cleanedFields.filter((field) => !excludeSet.has(normalizeDetailFieldName(field?.fieldName))))
|
|
158
163
|
.slice(0, DETAIL_MATERIAL_FIELD_LIMIT)
|
|
159
164
|
.map((field) => ({
|
|
@@ -167,7 +172,7 @@ async function fetchOneDetail(env, requestId, userId, options) {
|
|
|
167
172
|
const metrics = extractRowMetrics(usableFields);
|
|
168
173
|
return {
|
|
169
174
|
requestId,
|
|
170
|
-
|
|
175
|
+
workflowName,
|
|
171
176
|
formFields: picked,
|
|
172
177
|
contextAvailable: picked.length > 0,
|
|
173
178
|
excludeTag: excludeTagOf(excludeFields),
|
|
@@ -240,7 +245,7 @@ export async function fetchRequestDetailsBatch(env, requestIds, options = {}) {
|
|
|
240
245
|
failures.push({ requestId, error: reason });
|
|
241
246
|
details.set(requestId, {
|
|
242
247
|
requestId,
|
|
243
|
-
|
|
248
|
+
workflowName: '',
|
|
244
249
|
formFields: [],
|
|
245
250
|
contextAvailable: false,
|
|
246
251
|
excludeTag: '',
|
|
@@ -124,6 +124,46 @@ export async function collectRawTodos(args, env) {
|
|
|
124
124
|
if (pageRows.length < pageSize)
|
|
125
125
|
break;
|
|
126
126
|
}
|
|
127
|
+
// ① 详情回填(2026-11-03 用户定:取完列表**紧接着**拉流程详情)
|
|
128
|
+
// 目的:`getTodoListData.displayData` 可能没有 `workflowName`,缺了分组会整片落到 UNKNOWN_GROUP;
|
|
129
|
+
// 这里全量拉一遍详情(缓存优先,热缓存 0 请求),列表缺名时用详情 basic 的 workflowName 回填。
|
|
130
|
+
// 清洗口径照旧(分发字段 / excludeOriginFormDataFields / 200 字段 / 500 字),
|
|
131
|
+
// 但 basic 只保留 workflowName,其余字段丢弃(见 todoDetailFetcher + todoDetailCache v4)。
|
|
132
|
+
const workflowNames = new Map();
|
|
133
|
+
const createrNames = new Map();
|
|
134
|
+
for (const row of items) {
|
|
135
|
+
if (!row.requestId)
|
|
136
|
+
continue;
|
|
137
|
+
const name = String(row.workflowName ?? '').trim();
|
|
138
|
+
if (name)
|
|
139
|
+
workflowNames.set(row.requestId, name);
|
|
140
|
+
if (row.createrName)
|
|
141
|
+
createrNames.set(row.requestId, { createrName: row.createrName });
|
|
142
|
+
}
|
|
143
|
+
const detailBackfill = { requested: 0, cacheHit: 0, fetched: 0, failed: 0, nameFilled: 0 };
|
|
144
|
+
let allFacts = new Map();
|
|
145
|
+
if (items.length > 0) {
|
|
146
|
+
const detailIds = [...new Set(items.map((row) => row.requestId).filter(Boolean))];
|
|
147
|
+
const { facts, stats } = await fetchDetailFacts(env, detailIds, args, stampsOfRows(items), workflowNames, createrNames);
|
|
148
|
+
allFacts = facts;
|
|
149
|
+
detailBackfill.requested = stats.requested;
|
|
150
|
+
detailBackfill.cacheHit = stats.cacheHit;
|
|
151
|
+
detailBackfill.fetched = stats.fetched;
|
|
152
|
+
detailBackfill.failed = stats.failed;
|
|
153
|
+
for (const row of items) {
|
|
154
|
+
const fact = facts.get(row.requestId);
|
|
155
|
+
if (!fact)
|
|
156
|
+
continue;
|
|
157
|
+
if (!String(row.workflowName ?? '').trim() && fact.workflowName) {
|
|
158
|
+
row.workflowName = fact.workflowName;
|
|
159
|
+
workflowNames.set(row.requestId, fact.workflowName);
|
|
160
|
+
detailBackfill.nameFilled += 1;
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
if (detailBackfill.nameFilled > 0) {
|
|
164
|
+
warnings.push(`有 ${detailBackfill.nameFilled} 条列表数据缺少工作流名称,已用流程详情数据(basic.workflowName)回填`);
|
|
165
|
+
}
|
|
166
|
+
}
|
|
127
167
|
// 刷新本地查询快照(本地写文件,不联网):批量写门禁以「最近一次查询结果」为准,
|
|
128
168
|
// 不写会让 todoSmartConvert 取到的 ID 在 workflow.batch* 那里被判成「不在快照里」。
|
|
129
169
|
await saveSearchIndex({
|
|
@@ -197,8 +237,9 @@ export async function collectRawTodos(args, env) {
|
|
|
197
237
|
// 详情是流水线中间数据,smartGroup / summaryContext 需要时现场拉取(带缓存)。
|
|
198
238
|
// 例外:**有意图时**,ai二次分组要先看到表单字段,这里就把素材准备好(见下)。
|
|
199
239
|
detailStats = {
|
|
200
|
-
deferred:
|
|
201
|
-
note: '
|
|
240
|
+
deferred: false,
|
|
241
|
+
note: '详情已在 collect 阶段全量回填(缓存优先):仅 basic.workflowName 保留,其余 basic 字段与素材无关',
|
|
242
|
+
detailBackfill,
|
|
202
243
|
summaryCached: cachedSummaryIds.size,
|
|
203
244
|
summaryCacheFile: summaryCache.file,
|
|
204
245
|
summaryCachePruned: summaryCache.pruned,
|
|
@@ -214,16 +255,17 @@ export async function collectRawTodos(args, env) {
|
|
|
214
255
|
.flatMap((group) => group.requestDatas ?? []);
|
|
215
256
|
const targetIds = [...new Set(targetRows.map((row) => row.requestId).filter(Boolean))];
|
|
216
257
|
if (targetIds.length > 0) {
|
|
217
|
-
|
|
218
|
-
for (const
|
|
219
|
-
|
|
258
|
+
// 复用 ① 已回填的 facts(不再二次取数)
|
|
259
|
+
for (const requestId of targetIds) {
|
|
260
|
+
const fact = allFacts.get(requestId);
|
|
261
|
+
if (fact && fact.fields.length > 0)
|
|
220
262
|
fieldsById.set(requestId, fact.fields);
|
|
221
263
|
}
|
|
222
264
|
detailStats.groupingMaterial = {
|
|
223
265
|
requested: targetIds.length,
|
|
224
|
-
cacheHit:
|
|
225
|
-
fetched:
|
|
226
|
-
failed:
|
|
266
|
+
cacheHit: detailBackfill.cacheHit,
|
|
267
|
+
fetched: detailBackfill.fetched,
|
|
268
|
+
failed: detailBackfill.failed,
|
|
227
269
|
withFields: fieldsById.size,
|
|
228
270
|
};
|
|
229
271
|
}
|
|
@@ -7,7 +7,7 @@ export const UNKNOWN_DATE = '未知日期';
|
|
|
7
7
|
export const DEFAULT_TOP_N = 10;
|
|
8
8
|
export const STAGE_VALUES = [
|
|
9
9
|
'auto', 'collect', 'group', 'smartGroup',
|
|
10
|
-
'summaryContext', 'summary', 'groupSummaryContext', 'groupSummary',
|
|
10
|
+
'summaryContext', 'summary', 'subGroup', 'groupSummaryContext', 'groupSummary',
|
|
11
11
|
'aggregate',
|
|
12
12
|
];
|
|
13
13
|
export function asRecord(value) {
|
|
@@ -137,6 +137,7 @@ export const ALLOWED_INPUT_KEYS = [
|
|
|
137
137
|
'aiGroupSummaries',
|
|
138
138
|
'withDetailContext',
|
|
139
139
|
'withGroupSummaryContext',
|
|
140
|
+
'withSubGroup',
|
|
140
141
|
'detailPrefetch',
|
|
141
142
|
'maxCharsPerBatch',
|
|
142
143
|
'maxItemsPerBatch',
|
|
@@ -3,17 +3,16 @@ import { readBoundedInt } from './todoSmartConvert.core.js';
|
|
|
3
3
|
import { openDetailCache, DETAIL_CACHE_ENTRY_VERSION } from './todoDetailCache.js';
|
|
4
4
|
import { excludeTagFor } from './aigroupRules.js';
|
|
5
5
|
/**
|
|
6
|
-
*
|
|
6
|
+
* 把「排除清单过滤后的 formData 字段」拼成喂模型的文本。
|
|
7
7
|
*
|
|
8
|
-
* 每行一条 `fieldName:value
|
|
8
|
+
* 每行一条 `fieldName:value`;2026-11-03 起基础信息(basic)整体丢弃、只有 `workflowName` 保留在
|
|
9
|
+
* `DetailFact` 上用于分组回填,**不进素材**。
|
|
9
10
|
* 字段来源与截断口径见 `todoDetailFetcher`(排除清单 → ≤200 个字段 → 单值 ≤500 字)。
|
|
10
11
|
*/
|
|
11
12
|
export function contextOfDetail(detail) {
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
const fieldLines = (detail.formFields ?? []).map((field) => `${field.fieldName}:${field.value}`);
|
|
16
|
-
return [...basicLines, ...fieldLines].join('\n');
|
|
13
|
+
// 2026-11-03 用户定:流程详情接口返回的 basic 基础信息直接丢弃(只留 workflowName 用于分组回填,
|
|
14
|
+
// 且不进素材)。因此素材就是清洗后的表单字段,逐行 `fieldName:value`。
|
|
15
|
+
return (detail.formFields ?? []).map((field) => `${field.fieldName}:${field.value}`).join('\n');
|
|
17
16
|
}
|
|
18
17
|
const EMPTY_DETAIL_STATS = {
|
|
19
18
|
requested: 0,
|
|
@@ -57,7 +56,11 @@ function materialFieldsOf(detail) {
|
|
|
57
56
|
*
|
|
58
57
|
* 失败不致命:返回已拿到的部分 + warning,调用方按「无详情」降级。
|
|
59
58
|
*/
|
|
60
|
-
export async function fetchDetailFacts(env, requestIds, args, stamps
|
|
59
|
+
export async function fetchDetailFacts(env, requestIds, args, stamps,
|
|
60
|
+
/** 列表行的 `requestId → workflowName`(详情回填与 excludeTag 校验用) */
|
|
61
|
+
names,
|
|
62
|
+
/** 列表行的 `requestId → createrName`(内部留言「发起人」行兜底) */
|
|
63
|
+
createrNames) {
|
|
61
64
|
const unique = [...new Set(requestIds.filter(Boolean))];
|
|
62
65
|
const facts = new Map();
|
|
63
66
|
const warnings = [];
|
|
@@ -72,15 +75,16 @@ export async function fetchDetailFacts(env, requestIds, args, stamps) {
|
|
|
72
75
|
const missing = [];
|
|
73
76
|
for (const requestId of unique) {
|
|
74
77
|
const hit = cache.get(requestId, stamps?.get(requestId));
|
|
75
|
-
if (!hit || hit.excludeTag !== excludeTagFor(hit.
|
|
78
|
+
if (!hit || hit.excludeTag !== excludeTagFor(hit.workflowName ?? names?.get(requestId) ?? '')) {
|
|
76
79
|
missing.push(requestId);
|
|
77
80
|
continue;
|
|
78
81
|
}
|
|
79
82
|
facts.set(requestId, {
|
|
80
|
-
context: contextOfDetail({
|
|
83
|
+
context: contextOfDetail({ formFields: hit.fields }),
|
|
81
84
|
contextAvailable: hit.fields.length > 0,
|
|
82
85
|
metrics: hit.metrics,
|
|
83
86
|
fields: hit.fields,
|
|
87
|
+
workflowName: hit.workflowName || (names?.get(requestId) ?? ''),
|
|
84
88
|
});
|
|
85
89
|
stats.cacheHit += 1;
|
|
86
90
|
}
|
|
@@ -91,6 +95,7 @@ export async function fetchDetailFacts(env, requestIds, args, stamps) {
|
|
|
91
95
|
const { details, stats: fetchStats } = await fetchRequestDetailsBatch(env, missing, {
|
|
92
96
|
concurrency: readBoundedInt(args.detailConcurrency, 'detailConcurrency', 10, 1, 32),
|
|
93
97
|
timeoutMs: readBoundedInt(args.detailTimeoutMs, 'detailTimeoutMs', 10_000, 1_000, 60_000),
|
|
98
|
+
...(createrNames ? { rowMeta: createrNames } : {}),
|
|
94
99
|
});
|
|
95
100
|
stats.failed = fetchStats.failed;
|
|
96
101
|
stats.concurrency = fetchStats.concurrency;
|
|
@@ -100,6 +105,7 @@ export async function fetchDetailFacts(env, requestIds, args, stamps) {
|
|
|
100
105
|
contextAvailable: detail.formFields.length > 0,
|
|
101
106
|
metrics: detail.metrics ?? {},
|
|
102
107
|
fields: materialFieldsOf(detail),
|
|
108
|
+
workflowName: detail.workflowName || (names?.get(requestId) ?? ''),
|
|
103
109
|
};
|
|
104
110
|
facts.set(requestId, fact);
|
|
105
111
|
stats.fetched += 1;
|
|
@@ -110,7 +116,7 @@ export async function fetchDetailFacts(env, requestIds, args, stamps) {
|
|
|
110
116
|
// 详情为空也写缓存:否则这类条目每次都要重拉
|
|
111
117
|
if (cache.set(requestId, stamps?.get(requestId), {
|
|
112
118
|
v: DETAIL_CACHE_ENTRY_VERSION,
|
|
113
|
-
|
|
119
|
+
workflowName: fact.workflowName,
|
|
114
120
|
metrics: fact.metrics,
|
|
115
121
|
fields: fact.fields,
|
|
116
122
|
excludeTag: detail.excludeTag,
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { workflowValidationError } from '../../errors.js';
|
|
2
|
-
import { generalRules } from './aigroupRules.js';
|
|
3
2
|
import { UNKNOWN_GROUP, groupKeyOf, readGroupBy, readItems, readTopN, assertKnownKeys, } from './todoSmartConvert.core.js';
|
|
4
3
|
import { intentAppliesToKind, } from './businessRules.js';
|
|
5
4
|
/** 紧急程度以 requestLevel=2 或显示文本「紧急」为准;1 级是「重要」。 */
|
|
@@ -327,16 +326,11 @@ export function runGroup(args) {
|
|
|
327
326
|
const { rawCount, rows, duplicateCount, unreadableCount } = readItems(args.items);
|
|
328
327
|
const groupBy = readGroupBy(args.groupBy);
|
|
329
328
|
const topN = readTopN(args.topN);
|
|
330
|
-
//
|
|
331
|
-
//
|
|
332
|
-
|
|
333
|
-
const pgTitle = pgConfig?.title?.trim() || PRIORITY_GROUP_TITLE;
|
|
334
|
-
const pgRules = new Set(pgConfig?.rules ?? ['overdue', 'levelFallback']);
|
|
335
|
-
const priority = selectPriorityRows(rows, pgRules);
|
|
336
|
-
const priorityRows = sortPriorityRows(priority.rows);
|
|
337
|
-
const restRows = rows;
|
|
329
|
+
// 2026-11-03 用户定:分组阶段**不再**产出「建议优先处理的流程」——它是最终结构上的一个置顶
|
|
330
|
+
// 视图,等摘要全部回填后用 `assemblePriorityGroup()` 按同一条规则从成品数据里筛出来。
|
|
331
|
+
// 这样前期(摘要单位、闸门、统计)都只需处理一份数据,不必到处特判 topPriority。
|
|
338
332
|
const buckets = new Map();
|
|
339
|
-
for (const row of
|
|
333
|
+
for (const row of rows) {
|
|
340
334
|
const key = groupKeyOf(row, groupBy);
|
|
341
335
|
let bucket = buckets.get(key);
|
|
342
336
|
if (!bucket) {
|
|
@@ -364,20 +358,8 @@ export function runGroup(args) {
|
|
|
364
358
|
stats: statsOf(bucket.rows),
|
|
365
359
|
...(bucket.ids.length > 1 ? { workflowIds: bucket.ids } : {}),
|
|
366
360
|
}));
|
|
367
|
-
const groups =
|
|
368
|
-
|
|
369
|
-
id: PRIORITY_GROUP_ID,
|
|
370
|
-
topPriority: true,
|
|
371
|
-
title: pgTitle,
|
|
372
|
-
count: priorityRows.length,
|
|
373
|
-
requestDatas: priorityRows.map((row) => toRequestData(row)),
|
|
374
|
-
stats: statsOf(priorityRows),
|
|
375
|
-
}, ...workflowGroups]
|
|
376
|
-
: workflowGroups;
|
|
377
|
-
const displayedWorkflow = workflowGroups.slice(0, topN);
|
|
378
|
-
const displayed = priorityRows.length > 0 && groupBy === 'workflow'
|
|
379
|
-
? [groups[0], ...displayedWorkflow]
|
|
380
|
-
: displayedWorkflow;
|
|
361
|
+
const groups = workflowGroups;
|
|
362
|
+
const displayed = workflowGroups.slice(0, topN);
|
|
381
363
|
const rest = workflowGroups.slice(topN);
|
|
382
364
|
const restCount = rest.reduce((sum, group) => sum + group.count, 0);
|
|
383
365
|
const overall = statsOf(rows);
|
|
@@ -394,20 +376,6 @@ export function runGroup(args) {
|
|
|
394
376
|
? `有 ${unknownGroupCount} 条缺少工作流名称,已归入「${UNKNOWN_GROUP}」`
|
|
395
377
|
: `有 ${unknownGroupCount} 条缺少分组字段,已归入「${UNKNOWN_GROUP}」`);
|
|
396
378
|
}
|
|
397
|
-
if (priorityRows.length > 0 && groupBy === 'workflow') {
|
|
398
|
-
const levelText = priority.targetLevel === 2
|
|
399
|
-
? '紧急(requestLevel=2)'
|
|
400
|
-
: priority.targetLevel === 1
|
|
401
|
-
? '重要(requestLevel=1;本次无 2 级数据,已按规则降级取 1,0 级不取)'
|
|
402
|
-
: '无等级(本次整批没有 ≥1 级的条目,只按超时筛)';
|
|
403
|
-
warnings.push(`「${pgTitle}」筛出 ${priorityRows.length} 条:超时 ${priority.overdueCount} 条 / ` +
|
|
404
|
-
`等级命中 ${priority.levelCount} 条(两者都满足 ${priority.bothCount} 条),等级口径=${levelText};` +
|
|
405
|
-
`这 ${priorityRows.length} 条同时保留在各自工作流分组中(叠加视图:Σcount 会大于 totalCount,` +
|
|
406
|
-
`totalCount 按去重条数计 = ${rows.length})`);
|
|
407
|
-
}
|
|
408
|
-
else if (priorityRows.length === 0 && groupBy === 'workflow') {
|
|
409
|
-
warnings.push(`本次没有超时条目,也没有 requestLevel≥1 的条目,故不输出「${PRIORITY_GROUP_TITLE}」分组`);
|
|
410
|
-
}
|
|
411
379
|
if (rest.length > 0) {
|
|
412
380
|
warnings.push(`markdown 只展示前 ${topN} 个工作流分组,其余 ${rest.length} 组共 ${restCount} 条仍在 wfIdGroup 中(未截断)`);
|
|
413
381
|
}
|
|
@@ -442,7 +410,7 @@ export function runGroup(args) {
|
|
|
442
410
|
},
|
|
443
411
|
wfIdGroup: groups,
|
|
444
412
|
/** 第二部分(非优先组)的总条数与组数,前端折叠/分页直接用它,不用自己减 */
|
|
445
|
-
restTotal:
|
|
413
|
+
restTotal: rows.length,
|
|
446
414
|
restGroupCount: workflowGroups.length,
|
|
447
415
|
restGroups: rest.length > 0 ? { groupCount: rest.length, count: restCount } : null,
|
|
448
416
|
warnings,
|
package/dist/shortcuts/workflow/operations/todoSmartConvert/todoSmartConvert.groupSummary.js
CHANGED
|
@@ -69,8 +69,9 @@ export function collectGroupSummaryBatches(groups, isCtxEmpty, maxCharsFor = ()
|
|
|
69
69
|
continue;
|
|
70
70
|
const kind = detectBusinessKind(group.title);
|
|
71
71
|
for (const sub of groupItemsOf(group)) {
|
|
72
|
-
// CLI
|
|
73
|
-
|
|
72
|
+
// 已有摘要就不产批次:①CLI 固定文案(needAI:false);②模型随 aiGroups 一起给的
|
|
73
|
+
// 子组摘要(2026-11-03 合并交互)——两者都不需要再问一次模型。
|
|
74
|
+
if ((sub.summary ?? '').trim() !== '')
|
|
74
75
|
continue;
|
|
75
76
|
const allRows = Array.isArray(sub.requestDatas) ? sub.requestDatas : [];
|
|
76
77
|
const rows = isCtxEmpty ? allRows.filter((row) => !isCtxEmpty(row.requestId)) : allRows;
|