openpond 0.2.73 → 0.2.75
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/dist/app-server.js +1 -1
- package/dist/chunks/{acp-35QBGOMJ.js → acp-HGJMC75K.js} +1 -1
- package/dist/chunks/{acp-agent-4PKMX52I.js → acp-agent-CWV5NF6V.js} +1 -1
- package/dist/chunks/{app-layer-42ZKHTPN.js → app-layer-76YRQY7S.js} +1 -1
- package/dist/chunks/{app-server-evaluations-5JVNCET7.js → app-server-evaluations-PQDIMJJ7.js} +1 -1
- package/dist/chunks/{app-server-harness-services-4E236TXE.js → app-server-harness-services-5MB7CCCT.js} +1 -1
- package/dist/chunks/{app-server-runtime-CI2NTKX7.js → app-server-runtime-N3XZV35H.js} +1 -1
- package/dist/chunks/{apps-EGFRTFAJ.js → apps-DJQ2ZJKC.js} +1 -1
- package/dist/chunks/{chunk-QKGNAYSC.js → chunk-2HWSF4FS.js} +1 -1
- package/dist/chunks/{chunk-KQ7RFPG5.js → chunk-3SIZBCEO.js} +1 -1
- package/dist/chunks/{chunk-TP222CV2.js → chunk-5SBKDKGI.js} +1 -1
- package/dist/chunks/{chunk-U73T66FP.js → chunk-5VHHQZMT.js} +1 -1
- package/dist/chunks/{chunk-NDNSLCPE.js → chunk-5W2OJKJW.js} +1 -1
- package/dist/chunks/{chunk-XSDWRRZP.js → chunk-6EZHEVXS.js} +1 -1
- package/dist/chunks/{chunk-YIZE3M5S.js → chunk-7NLKMY7L.js} +1 -1
- package/dist/chunks/{chunk-MHSSPMLB.js → chunk-B7ELZHQN.js} +1 -1
- package/dist/chunks/{chunk-KE5PYRJ6.js → chunk-BZPNCSUY.js} +1 -1
- package/dist/chunks/{chunk-IXMY4EKS.js → chunk-CABXOJ3I.js} +1 -1
- package/dist/chunks/{chunk-E7SQBMYW.js → chunk-CBJ33EIB.js} +1 -1
- package/dist/chunks/{chunk-2IIVBBF5.js → chunk-CILYQK2G.js} +1 -1
- package/dist/chunks/{chunk-OBMMO5NC.js → chunk-CNVPZKJG.js} +3 -3
- package/dist/chunks/{chunk-4KG7GJ5O.js → chunk-CZ2JSEUK.js} +1 -1
- package/dist/chunks/{chunk-H5EHSILL.js → chunk-D2PEB6AJ.js} +1 -1
- package/dist/chunks/{chunk-FRQYH4QD.js → chunk-DAWHZU7L.js} +1 -1
- package/dist/chunks/{chunk-WOYBWRRV.js → chunk-DVBZBJSK.js} +1 -1
- package/dist/chunks/{chunk-MXDSB2C5.js → chunk-EOQTBH4U.js} +1 -1
- package/dist/chunks/{chunk-P7RLDDPN.js → chunk-FPW3RFZR.js} +1 -1
- package/dist/chunks/{chunk-WAWVFSIQ.js → chunk-FWYJ3MIN.js} +1 -1
- package/dist/chunks/{chunk-5VQK3CCJ.js → chunk-FXLLAAGI.js} +1 -1
- package/dist/chunks/{chunk-ODH5XGE6.js → chunk-HCQTAFTX.js} +1 -1
- package/dist/chunks/{chunk-FCC24XUI.js → chunk-HHLQG7PN.js} +1 -1
- package/dist/chunks/{chunk-TRXOE7TT.js → chunk-HRJ4EPR3.js} +1 -1
- package/dist/chunks/{chunk-O6L4NO3M.js → chunk-HYYQCBX5.js} +1 -1
- package/dist/chunks/{chunk-OFC5N6R3.js → chunk-IPH4LGK2.js} +6 -6
- package/dist/chunks/{chunk-3XNUG4FO.js → chunk-JBIAEQHI.js} +1 -1
- package/dist/chunks/{chunk-XN5BXPAT.js → chunk-JQDZYC72.js} +1 -1
- package/dist/chunks/{chunk-3BIB6KKL.js → chunk-JRW6MFV6.js} +1 -1
- package/dist/chunks/{chunk-EAW5FHU4.js → chunk-JSJB3PR2.js} +2 -2
- package/dist/chunks/{chunk-O4YHISU2.js → chunk-KAW26NGC.js} +1 -1
- package/dist/chunks/{chunk-HIPKU57Y.js → chunk-LK7TJYEP.js} +1 -1
- package/dist/chunks/{chunk-2IECLXB2.js → chunk-LRGMGXL2.js} +1 -1
- package/dist/chunks/{chunk-G2P2PYEO.js → chunk-NACSY3HS.js} +1 -1
- package/dist/chunks/{chunk-E5HDJCKK.js → chunk-NGTNI3YX.js} +1 -1
- package/dist/chunks/{chunk-ONR2AKRI.js → chunk-O5FYAVDK.js} +4 -4
- package/dist/chunks/{chunk-LWF5MQJ4.js → chunk-OJEIYU7D.js} +1 -1
- package/dist/chunks/{chunk-AWUSAHXG.js → chunk-OOSF2SPF.js} +1 -1
- package/dist/chunks/{chunk-JG6JA7YT.js → chunk-P4SXDU55.js} +1 -1
- package/dist/chunks/{chunk-DUR32LJG.js → chunk-PQGR2MTX.js} +1 -1
- package/dist/chunks/{chunk-6IKIGVJF.js → chunk-QSITPC3X.js} +1 -1
- package/dist/chunks/chunk-RGSMU6N4.js +2 -0
- package/dist/chunks/{chunk-CBD554GZ.js → chunk-RORT6K3Y.js} +1 -1
- package/dist/chunks/{chunk-OXUS4QOT.js → chunk-SFLL3TKE.js} +1 -1
- package/dist/chunks/chunk-SYFJVLEL.js +2 -0
- package/dist/chunks/{chunk-6KKWSUEW.js → chunk-THLBUON5.js} +1 -1
- package/dist/chunks/{chunk-X4CN3FIN.js → chunk-VU6S2S3O.js} +1 -1
- package/dist/chunks/{chunk-H2YQ4AA2.js → chunk-W5FL7EH2.js} +1 -1
- package/dist/chunks/{chunk-WBV6A6NS.js → chunk-WHI4XNBI.js} +1 -1
- package/dist/chunks/{chunk-FA3GXQYA.js → chunk-WOA6XFQU.js} +1 -1
- package/dist/chunks/{chunk-SUILNZQJ.js → chunk-WOER246B.js} +1 -1
- package/dist/chunks/{chunk-645T6LH7.js → chunk-XJP7RIHL.js} +1 -1
- package/dist/chunks/{chunk-KOLVSUOS.js → chunk-Z3OW37CO.js} +1 -1
- package/dist/chunks/{chunk-OUOOKEU3.js → chunk-ZACCHQWK.js} +1 -1
- package/dist/chunks/{chunk-3V2XAYYA.js → chunk-ZKH4Z3EQ.js} +1 -1
- package/dist/chunks/{chunk-OXRN2257.js → chunk-ZLYQR44C.js} +1 -1
- package/dist/chunks/chunk-ZQOJLPWD.js +2 -0
- package/dist/chunks/{chunk-EZ435RGA.js → chunk-ZYJHMX4T.js} +1 -1
- package/dist/chunks/{cli-NHRYN2G3.js → cli-B6JFFXMI.js} +1 -1
- package/dist/chunks/{command-54MMVWS2.js → command-GZ3Z37WJ.js} +3 -3
- package/dist/chunks/{configuration-command-XMXTU2FQ.js → configuration-command-OHW7RPSC.js} +1 -1
- package/dist/chunks/{connected-app-executor-WJEDXUA4.js → connected-app-executor-P35Y6B5Y.js} +1 -1
- package/dist/chunks/{connected-evidence-NFQPO5E3.js → connected-evidence-I4I7DQRX.js} +1 -1
- package/dist/chunks/{connected-starting-assets-M54PSOEP.js → connected-starting-assets-Q7CYZT25.js} +1 -1
- package/dist/chunks/{continual-C2YWPEJZ.js → continual-3OIKJ3PG.js} +1 -1
- package/dist/chunks/{core-commands-SY4I5FHE.js → core-commands-BWDKP6AI.js} +1 -1
- package/dist/chunks/{dataset-preparation-authoring-CH6Z4NE6.js → dataset-preparation-authoring-RPYFOFBV.js} +1 -1
- package/dist/chunks/{datasets-2OQDMF7E.js → datasets-2W4JPKSP.js} +1 -1
- package/dist/chunks/{desktop-test-VNMR5H4I.js → desktop-test-EUBEZJDU.js} +1 -1
- package/dist/chunks/{evaluation-coordination-GULGPATI.js → evaluation-coordination-IYNDZB6X.js} +1 -1
- package/dist/chunks/{experiment-improvements-XNXTU6ZA.js → experiment-improvements-D3DHZ7QI.js} +1 -1
- package/dist/chunks/{experiments-DZX6ZU6F.js → experiments-7OXSDLJG.js} +1 -1
- package/dist/chunks/{experiments-signal-QDVPO3M5.js → experiments-signal-6SWD3TSR.js} +1 -1
- package/dist/chunks/{help-UCN67FN7.js → help-XVZ4RRAB.js} +1 -1
- package/dist/chunks/{host-profile-evaluation-tools-XMGGHVH3.js → host-profile-evaluation-tools-I7ESCZH7.js} +1 -1
- package/dist/chunks/{host-profile-external-dataset-C6ZPMTX6.js → host-profile-external-dataset-MD4X7BCL.js} +1 -1
- package/dist/chunks/{hosted-app-server-composition-U7WGMN5B.js → hosted-app-server-composition-PYKNSE3O.js} +1 -1
- package/dist/chunks/{hosted-experiment-improvement-VQN6PJKR.js → hosted-experiment-improvement-5L3Z7IV6.js} +1 -1
- package/dist/chunks/{hosted-harness-runtime-O6E5LCGN.js → hosted-harness-runtime-XDCLEP3C.js} +1 -1
- package/dist/chunks/{hosted-profile-candidate-HQ544PNP.js → hosted-profile-candidate-6Q3GOLII.js} +1 -1
- package/dist/chunks/{hosted-profile-compiler-K4OACT7S.js → hosted-profile-compiler-FYBOGHZF.js} +1 -1
- package/dist/chunks/{hosted-profile-evaluation-control-TKYM73YY.js → hosted-profile-evaluation-control-MXXZR6XA.js} +1 -1
- package/dist/chunks/{hosted-profile-evaluation-inspection-HFCFUYQ4.js → hosted-profile-evaluation-inspection-4J7LAVY2.js} +1 -1
- package/dist/chunks/{hosted-profile-evaluation-preparation-OJ6AR5P5.js → hosted-profile-evaluation-preparation-EF43QUMG.js} +1 -1
- package/dist/chunks/{human-review-DNVIVJRK.js → human-review-6WAUW3BG.js} +1 -1
- package/dist/chunks/{import-QT5AKEA3.js → import-333V3CGC.js} +1 -1
- package/dist/chunks/{local-harness-improvement-runtime-BWZBMOGL.js → local-harness-improvement-runtime-HC42DG74.js} +1 -1
- package/dist/chunks/{local-harness-taskset-review-JL2XNXML.js → local-harness-taskset-review-CUL73U4A.js} +1 -1
- package/dist/chunks/{opchat-7PWUXQSY.js → opchat-R7FBOSCD.js} +1 -1
- package/dist/chunks/{opchat-bounded-chat-B3GOCGWY.js → opchat-bounded-chat-IOV6FYBH.js} +1 -1
- package/dist/chunks/{organizations-TWBMN7KF.js → organizations-EG5BSG26.js} +1 -1
- package/dist/chunks/{profile-RVARQYG4.js → profile-VLGYQXEP.js} +1 -1
- package/dist/chunks/{project-action-payload-65MTQMQW.js → project-action-payload-5PL65D3W.js} +1 -1
- package/dist/chunks/{project-agent-ZC33YRZE.js → project-agent-XT47W7MT.js} +1 -1
- package/dist/chunks/{published-experiment-source-L7BER6AE.js → published-experiment-source-7TDPGSOJ.js} +1 -1
- package/dist/chunks/{refiner-profile-service-56776J7B.js → refiner-profile-service-4RRRB33P.js} +1 -1
- package/dist/chunks/{runtime-GN2H2R7L.js → runtime-K3BUZ3ZQ.js} +1 -1
- package/dist/chunks/{sandbox-command-HWIAH6JA.js → sandbox-command-D7T2GKQA.js} +1 -1
- package/dist/chunks/{sandbox-template-MNZ6OXQQ.js → sandbox-template-WTIQRKE6.js} +1 -1
- package/dist/chunks/{saved-work-OMBDT3ZR.js → saved-work-GQEYG77G.js} +1 -1
- package/dist/chunks/{setup-C6673TJK.js → setup-5MZKOZY2.js} +1 -1
- package/dist/chunks/{src-UHNSXT34.js → src-PEOADF2P.js} +2 -2
- package/dist/chunks/{src-HHFJIPL5.js → src-ZUOZOCQ2.js} +1 -1
- package/dist/chunks/{standalone-experiment-turn-owner-UYPA6XHW.js → standalone-experiment-turn-owner-N7PEBGW3.js} +1 -1
- package/dist/chunks/{store-chat-resources-TYR7D2UP.js → store-chat-resources-7JEZFCC2.js} +1 -1
- package/dist/chunks/{store-continual-support-reviews-63YCKG3P.js → store-continual-support-reviews-RJ5OQZTC.js} +1 -1
- package/dist/chunks/{store-conversation-serving-PDSBGL3E.js → store-conversation-serving-D3HJ5OZK.js} +1 -1
- package/dist/chunks/{store-create-improve-RYASTT56.js → store-create-improve-ERPWR2LH.js} +1 -1
- package/dist/chunks/{store-datasets-PELTRO4A.js → store-datasets-R6P5KBAH.js} +1 -1
- package/dist/chunks/{store-evaluation-results-OUTNEMAY.js → store-evaluation-results-ZCABU3X5.js} +1 -1
- package/dist/chunks/{store-human-review-GIMAXCJQ.js → store-human-review-2PHLILEI.js} +1 -1
- package/dist/chunks/{store-learned-preference-migration-validation-DHOSHA6C.js → store-learned-preference-migration-validation-OGFFAM3Q.js} +1 -1
- package/dist/chunks/{store-local-experiments-AH4Z6RWX.js → store-local-experiments-ZG4NWB63.js} +1 -1
- package/dist/chunks/{store-model-batch-review-UUW6ZLDH.js → store-model-batch-review-LQAM7FQJ.js} +1 -1
- package/dist/chunks/{store-model-configuration-4U5A6DU7.js → store-model-configuration-3S74O2IQ.js} +1 -1
- package/dist/chunks/{store-model-project-preparation-MYHO43VH.js → store-model-project-preparation-ARDV4U77.js} +1 -1
- package/dist/chunks/{store-modification-recordings-OZBLFYCT.js → store-modification-recordings-BHJTHW3A.js} +1 -1
- package/dist/chunks/{store-task-inbox-M7YZNCRF.js → store-task-inbox-YRN2UDW3.js} +1 -1
- package/dist/chunks/{store-task-inventory-TTJQAM3T.js → store-task-inventory-6V4UX5BY.js} +1 -1
- package/dist/chunks/{store-taskset-drafts-4GVHDLJJ.js → store-taskset-drafts-H2O4CRIF.js} +1 -1
- package/dist/chunks/{store-training-MGGTGTV2.js → store-training-MQGXXKTX.js} +1 -1
- package/dist/chunks/{store-training-jobs-XKDUX4SV.js → store-training-jobs-YASPKBB3.js} +1 -1
- package/dist/chunks/{store-training-models-4S4ZT3BL.js → store-training-models-HAJCN3IS.js} +1 -1
- package/dist/chunks/{taskset-SLQSCYJI.js → taskset-65BR2KOE.js} +1 -1
- package/dist/chunks/{teams-bot-7U6JOV6T.js → teams-bot-VMG23AFI.js} +1 -1
- package/dist/chunks/{tool-learning-25Z2JOBS.js → tool-learning-YSYQEASN.js} +1 -1
- package/dist/chunks/training-5V53RWI7.js +2 -0
- package/dist/chunks/training-U6OPNRP4.js +2 -0
- package/dist/chunks/{training-2LUQ2IZM.js → training-YUWQXGJX.js} +1 -1
- package/dist/chunks/{training-hosted-NLXMISNL.js → training-hosted-KO4SCSLZ.js} +1 -1
- package/dist/chunks/{training-hosted-alphaedit-WGMJ3L2D.js → training-hosted-alphaedit-HQTKGEZU.js} +1 -1
- package/dist/chunks/{training-hosted-decision-66EUMUIW.js → training-hosted-decision-LN7MQGBF.js} +1 -1
- package/dist/chunks/{training-hosted-engram-QDXSJ77I.js → training-hosted-engram-7UAVQFBA.js} +1 -1
- package/dist/chunks/{training-hosted-modification-comparison-2MH5FZMZ.js → training-hosted-modification-comparison-ZOYOSVHI.js} +1 -1
- package/dist/chunks/{training-hosted-neuron-training-3QXKIEKT.js → training-hosted-neuron-training-37Y6WJH5.js} +1 -1
- package/dist/chunks/{training-hosted-serving-report-ZG75ACZK.js → training-hosted-serving-report-EXJ5X7GB.js} +1 -1
- package/dist/chunks/{training-hosted-steering-KFMTKCTX.js → training-hosted-steering-EAFICV6I.js} +1 -1
- package/dist/chunks/{training-model-start-NMQ55UHZ.js → training-model-start-5QB7A5TD.js} +1 -1
- package/dist/cli.js +1 -1
- package/dist/skills/manifest.json +1 -1
- package/dist/web/assets/{App-CV1p0_Zy.js → App-CqqK4NLa.js} +4 -4
- package/dist/web/assets/{AppDialog-DdGt7aU1.js → AppDialog-wmL4BlOJ.js} +1 -1
- package/dist/web/assets/AppTerminalPanel-BHFgtq4f.js +2 -0
- package/dist/web/assets/{AppToastContext-D7z0w1PS.js → AppToastContext-DyaZYQXu.js} +1 -1
- package/dist/web/assets/{AppsView-B-Ts-M_V.js → AppsView-C6u5q5ro.js} +1 -1
- package/dist/web/assets/{AttachmentTypeIcon-BJ5i12im.js → AttachmentTypeIcon-AqiS2gzg.js} +1 -1
- package/dist/web/assets/{BrowserSidebar-BVHthjXU.js → BrowserSidebar-nNTQ1E4K.js} +1 -1
- package/dist/web/assets/{CartesianChart-BuJ1wFS7.js → CartesianChart-C5ptcXRG.js} +1 -1
- package/dist/web/assets/{ChatTimelineEntry-CfiiTrK4.js → ChatTimelineEntry-DH0-itET.js} +1 -1
- package/dist/web/assets/{CollaborationTabs-1t9zAhDC.js → CollaborationTabs-C22BMWJ4.js} +1 -1
- package/dist/web/assets/{CommandMenu-DTB6xjGG.js → CommandMenu-CKtBVjuO.js} +1 -1
- package/dist/web/assets/{CommunityView-BjeZ56id.js → CommunityView-Baq8HqVm.js} +1 -1
- package/dist/web/assets/{ComposerAttachments-C_K_05H9.js → ComposerAttachments-BOyEXVhV.js} +1 -1
- package/dist/web/assets/{ComposerCreateImproveStrip-A38jnNGd.js → ComposerCreateImproveStrip-EbNwu1gE.js} +1 -1
- package/dist/web/assets/{ConversationImportsSettings-jwaoKQZt.js → ConversationImportsSettings-Cqg66Lcb.js} +1 -1
- package/dist/web/assets/{DatasetReviewImport-DZA1s3XG.js → DatasetReviewImport--FgZ3Zk-.js} +1 -1
- package/dist/web/assets/{ExperimentTrainingDataWorkspace-DowPuAXk.js → ExperimentTrainingDataWorkspace-B04Cg7Hc.js} +2 -2
- package/dist/web/assets/{FilePagePreview-11ZNRtdT.js → FilePagePreview-CeZF-oOW.js} +2 -2
- package/dist/web/assets/{GetStartedView-bLVKmjqg.js → GetStartedView-DOpCgmrC.js} +1 -1
- package/dist/web/assets/{GettingStartedDialog-BeimFLZh.js → GettingStartedDialog-tB38Q6JA.js} +1 -1
- package/dist/web/assets/{HostedModelLearningReview-DiFVb3WK.js → HostedModelLearningReview-CQ0bI6Np.js} +1 -1
- package/dist/web/assets/{HostedModelLearningSettings-DtUF5ejq.js → HostedModelLearningSettings-DEdV2dXx.js} +1 -1
- package/dist/web/assets/{HtmlVisual-CgVTWr64.js → HtmlVisual-krrlNGFX.js} +1 -1
- package/dist/web/assets/{LabModelVersionDetailPage-BvinwnBN.js → LabModelVersionDetailPage-DeVfdS7p.js} +1 -1
- package/dist/web/assets/{LabModelWorkspace-Q5DG2mLP.js → LabModelWorkspace-Di_yTjzH.js} +1 -1
- package/dist/web/assets/{LabSkillSidebar-cmhZzr4f.js → LabSkillSidebar-CNjUmnfC.js} +1 -1
- package/dist/web/assets/{LabsRoute-DS_mlprv.js → LabsRoute-Gznx60Cp.js} +4 -4
- package/dist/web/assets/{LearningBatchesPage-Cm-btgWc.js → LearningBatchesPage-CpZ0UTX3.js} +1 -1
- package/dist/web/assets/{MainChatThread-DbTn4Bag.js → MainChatThread-Dr2DipCD.js} +2 -2
- package/dist/web/assets/{MainPane-BtzUF6O_.js → MainPane-aEELnEKb.js} +7 -7
- package/dist/web/assets/{ModelProjectPageHeader-C4mgVJGx.js → ModelProjectPageHeader-BVwW-R0w.js} +1 -1
- package/dist/web/assets/{NativeSetupTerminal-bJpDkKk1.js → NativeSetupTerminal-BXvrxj-m.js} +2 -2
- package/dist/web/assets/{NativeSkillSidebar-BuToZvK-.js → NativeSkillSidebar-CYsBopsX.js} +1 -1
- package/dist/web/assets/{NewProjectDialog-F0BPQy0S.js → NewProjectDialog-BR5DChE9.js} +1 -1
- package/dist/web/assets/{OutputsPage-DC4g59_8.js → OutputsPage-CR8pWUj0.js} +1 -1
- package/dist/web/assets/{PageChrome-ufq2jePD.js → PageChrome-BXMG877B.js} +1 -1
- package/dist/web/assets/{ProjectsPage-7mbOvMfO.js → ProjectsPage-CwCes2kZ.js} +1 -1
- package/dist/web/assets/{RightChatPanelStack-sR9xN3RP.js → RightChatPanelStack-BvApbQCc.js} +1 -1
- package/dist/web/assets/RightSidebarHomePanel-Dm6hhkKw.js +1 -0
- package/dist/web/assets/{ScheduledWorkPage-s9CN6nR_.js → ScheduledWorkPage-nJJH1fwV.js} +1 -1
- package/dist/web/assets/{SettingsView-CZNWYK-D.js → SettingsView-CBZ6rqak.js} +3 -3
- package/dist/web/assets/{TasksetDraftEditorPrimitives-BnMqzE-T.js → TasksetDraftEditorPrimitives-Bcw6T4Lf.js} +1 -1
- package/dist/web/assets/{TeamChatView-XthM6n4S.js → TeamChatView-CIwlZFqB.js} +1 -1
- package/dist/web/assets/{TerminalOverlay--HCFZaQW.js → TerminalOverlay-Dhgy0NC3.js} +1 -1
- package/dist/web/assets/{TrainingCreationPanel-D2F6kPg_.js → TrainingCreationPanel-yLiEL2tM.js} +1 -1
- package/dist/web/assets/{TrainingDraftPanel-BurWPp9F.js → TrainingDraftPanel-Dng3C-zU.js} +1 -1
- package/dist/web/assets/{UsageSettingsSection-D7jdscDm.js → UsageSettingsSection-CTa7T7tS.js} +1 -1
- package/dist/web/assets/WorkSidebarPanel-BEIDC3vx.js +1 -0
- package/dist/web/assets/{WorkspaceDiffPanel-CPaCC1_p.js → WorkspaceDiffPanel-DnZlUEbx.js} +3 -3
- package/dist/web/assets/{WorkspaceEnvironmentMenu-BZxu6mUS.js → WorkspaceEnvironmentMenu-D-w36AYB.js} +1 -1
- package/dist/web/assets/{WorkspaceFileLocation-C4K_D_yh.js → WorkspaceFileLocation-D2kiU_FJ.js} +1 -1
- package/dist/web/assets/{WorkspaceGitDialogs-C0Yf29V0.js → WorkspaceGitDialogs-CylEGfzD.js} +1 -1
- package/dist/web/assets/{WorkspaceMonacoEditor-BRPLaFZS.js → WorkspaceMonacoEditor-ChBjvgxE.js} +3 -3
- package/dist/web/assets/{WorkspacePdfPreview-9wypyV6H.js → WorkspacePdfPreview-CBS6GjeP.js} +2 -2
- package/dist/web/assets/{WorkspacePresentationPreview-C-Cn-9pj.js → WorkspacePresentationPreview-DhltPUL4.js} +1 -1
- package/dist/web/assets/{bot-BuaAVlz6.js → bot-C0e4zzW4.js} +1 -1
- package/dist/web/assets/{chat-resources-DMPHClhQ.js → chat-resources-BFT0vtdv.js} +1 -1
- package/dist/web/assets/chevron-down-C4LIbeSz.js +1 -0
- package/dist/web/assets/chevron-right-BKelERU6.js +1 -0
- package/dist/web/assets/chevron-up-Dj1vY1ME.js +1 -0
- package/dist/web/assets/{chunk-C3TS766N-BXUEjt7d.js → chunk-C3TS766N-bHAuW3qR.js} +1 -1
- package/dist/web/assets/chunk-GS5HEE4M-DTj6NX5d.js +1 -0
- package/dist/web/assets/{client-C-ZuakZR.js → client-BO8YuI8Z.js} +1 -1
- package/dist/web/assets/{client-choice-storage-DWIA0Vou.js → client-choice-storage-D_6dVX8O.js} +1 -1
- package/dist/web/assets/{cloud-upload-B5LqiNCG.js → cloud-upload-U0f9MSd8.js} +1 -1
- package/dist/web/assets/{copy-BYIypHbq.js → copy-B0gWkglr.js} +1 -1
- package/dist/web/assets/{cssMode-ByypIqUN.js → cssMode-BkR1YcfF.js} +1 -1
- package/dist/web/assets/{dataset-workspaces-BTPi71mz.js → dataset-workspaces-DM2zGcAK.js} +1 -1
- package/dist/web/assets/{external-link-Cv7TDVPT.js → external-link-DymjzX8a.js} +1 -1
- package/dist/web/assets/{folder-open-DlIP3g5o.js → folder-open-BPA5YifJ.js} +1 -1
- package/dist/web/assets/{folder-plus-CXwFJqcY.js → folder-plus-BCcE8Q4i.js} +1 -1
- package/dist/web/assets/{git-commit-horizontal-DMh_-WxU.js → git-commit-horizontal-DbTJXbet.js} +1 -1
- package/dist/web/assets/{htmlMode-CQGeb-h5.js → htmlMode-z1rCf6pX.js} +1 -1
- package/dist/web/assets/{icons-CYvTltSH.js → icons-nr5d1kC-.js} +1 -1
- package/dist/web/assets/{image-Ci1JxTQX.js → image-Us0M7Xxi.js} +1 -1
- package/dist/web/assets/{index-CDtTBysF.js → index-DG0kf1wK.js} +2 -2
- package/dist/web/assets/{info-EjyMkVzV.js → info-M5kOSB9T.js} +1 -1
- package/dist/web/assets/{jsonMode-Dm6YK6Dw.js → jsonMode-AMfP-lcX.js} +1 -1
- package/dist/web/assets/loader-circle-C1-u7BUs.js +1 -0
- package/dist/web/assets/{lspLanguageFeatures-BjtOz-Ln.js → lspLanguageFeatures-C6uY6TKM.js} +1 -1
- package/dist/web/assets/{maximize-2-CvvoALtI.js → maximize-2-B2pi1o5S.js} +1 -1
- package/dist/web/assets/{message-square-CPtIPRtf.js → message-square-CPvsC3Wv.js} +1 -1
- package/dist/web/assets/{monaco.contribution-ClH8Tmjq.js → monaco.contribution-5F6IVWCS.js} +2 -2
- package/dist/web/assets/{monaco.contribution-wpC0-Kxw.js → monaco.contribution-BUi28toA.js} +2 -2
- package/dist/web/assets/{monaco.contribution-VSFFgrfZ.js → monaco.contribution-CfQvs13S.js} +2 -2
- package/dist/web/assets/{monaco.contribution-e5DNaEix.js → monaco.contribution-DySvt1jU.js} +2 -2
- package/dist/web/assets/{monitor-BroZpIvk.js → monitor-1YJYctCB.js} +1 -1
- package/dist/web/assets/{paperclip-DYZEL_Gi.js → paperclip-CNTReC0m.js} +1 -1
- package/dist/web/assets/{pdf-DkU37Bi0.js → pdf-DaNAfjLW.js} +1 -1
- package/dist/web/assets/play-DF5h_-8T.js +1 -0
- package/dist/web/assets/plus-D6oFNFQ0.js +1 -0
- package/dist/web/assets/{presentation-CddfsTzp.js → presentation-DbkiE2BE.js} +1 -1
- package/dist/web/assets/{python-CMdyfF2B.js → python-CDlD-992.js} +1 -1
- package/dist/web/assets/{refresh-cw-Cx_7Zlbl.js → refresh-cw-avBifyns.js} +1 -1
- package/dist/web/assets/{save-BaeHeBBw.js → save-DBayPmp_.js} +1 -1
- package/dist/web/assets/{settings-lists-CVg9h-5z.js → settings-lists-Cca729es.js} +1 -1
- package/dist/web/assets/square-CJccmW-i.js +1 -0
- package/dist/web/assets/{square-terminal-CBlQtWQw.js → square-terminal-D7snuW2g.js} +1 -1
- package/dist/web/assets/{submit-issue-command-L5--gt9i.js → submit-issue-command-wDL6xK3b.js} +1 -1
- package/dist/web/assets/{toggleHighContrast-hftC_Rxs.js → toggleHighContrast-CP0qM8JR.js} +1 -1
- package/dist/web/assets/training-KYW8yE6p.js +1 -0
- package/dist/web/assets/{training-model-data-vvvphDlO.js → training-model-data-CilS0W2N.js} +1 -1
- package/dist/web/assets/{tsMode-B0sZU1HD.js → tsMode-DxR6CkQb.js} +1 -1
- package/dist/web/assets/{upload-Bzt1ooBz.js → upload-DEtkeTGw.js} +1 -1
- package/dist/web/assets/{useAccountSettings-BnxwetkP.js → useAccountSettings-BTy8zF0n.js} +1 -1
- package/dist/web/assets/{useAgentInventory-D_qS4ols.js → useAgentInventory-8MWE3pbH.js} +1 -1
- package/dist/web/assets/{useChatContextSelection-D8aSVtCm.js → useChatContextSelection-CBVI5IYj.js} +1 -1
- package/dist/web/assets/{useLocalAgentSchedules-CUQ1MW4l.js → useLocalAgentSchedules-B09iSkPy.js} +1 -1
- package/dist/web/assets/{useQuery-9SCnxwmR.js → useQuery-CKHqHSr0.js} +1 -1
- package/dist/web/assets/{wifi-off-DWtVm7W7.js → wifi-off-C-GF_rPd.js} +1 -1
- package/dist/web/assets/{workers-B3jA6AOv.js → workers-CmqH-dTr.js} +1 -1
- package/dist/web/assets/x-CQ0pGF6Q.js +1 -0
- package/dist/web/assets/{yaml-BEUL30-5.js → yaml-J_HdACeF.js} +1 -1
- package/dist/web/index.html +1 -1
- package/docs/command-reference.md +1 -0
- package/package.json +1 -1
- package/dist/chunks/chunk-5AV2EWFX.js +0 -2
- package/dist/chunks/chunk-64EDQ7UV.js +0 -2
- package/dist/chunks/chunk-DLOJG7LP.js +0 -2
- package/dist/chunks/training-JA5ZQABE.js +0 -2
- package/dist/chunks/training-NL5GYZKU.js +0 -2
- package/dist/web/assets/AppTerminalPanel-B2p_tYh5.js +0 -2
- package/dist/web/assets/RightSidebarHomePanel-joZavyR9.js +0 -1
- package/dist/web/assets/WorkSidebarPanel-CmdXCmrZ.js +0 -1
- package/dist/web/assets/chevron-down-CkifKd_O.js +0 -1
- package/dist/web/assets/chevron-right-LsMXJ5SB.js +0 -1
- package/dist/web/assets/chevron-up-Dt5T2Sf5.js +0 -1
- package/dist/web/assets/chunk-GS5HEE4M-C0RLeIsy.js +0 -1
- package/dist/web/assets/loader-circle-AjP2mDJA.js +0 -1
- package/dist/web/assets/play-BrvX67t1.js +0 -1
- package/dist/web/assets/plus-DFjCZeRE.js +0 -1
- package/dist/web/assets/square-Di5JBnVr.js +0 -1
- package/dist/web/assets/training-CGYukv2L.js +0 -1
- package/dist/web/assets/x-EG07vYCF.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{i as e}from"./rolldown-runtime-Dd_uD5pT.js";import{g as t,m as n}from"./index-
|
|
1
|
+
import{i as e}from"./rolldown-runtime-Dd_uD5pT.js";import{g as t,m as n}from"./index-DG0kf1wK.js";import{h as r,m as i}from"./app-models-BUdzQbXo.js";import"./icons-nr5d1kC-.js";import{t as a}from"./message-square-CPvsC3Wv.js";import{E as o,Sn as s,Xt as c,en as l,ln as u,pn as d,qt as f}from"./App-CqqK4NLa.js";var p=e(t(),1),m=n();function h({open:e,query:t,projects:n,sessions:r,onQueryChange:h,onClose:v,onNewChat:x,onOpenProject:S,onOpenSession:C}){let w=t.trim().toLowerCase(),T=(0,p.useMemo)(()=>g(r,w,10),[w,r]),E=(0,p.useMemo)(()=>_(n,w,8),[w,n]);if(!e)return null;let D=()=>{let e=E[0];if(e){S(e);return}let t=T[0];t&&C(t)};return(0,m.jsx)(`div`,{className:`command-overlay`,role:`presentation`,onMouseDown:v,children:(0,m.jsxs)(`section`,{className:`command-menu`,role:`dialog`,"aria-modal":`true`,"aria-label":`Search chats and projects`,onMouseDown:e=>e.stopPropagation(),children:[(0,m.jsxs)(`div`,{className:`command-input-row`,children:[(0,m.jsx)(c,{size:17}),(0,m.jsx)(`input`,{autoFocus:!0,value:t,onChange:e=>h(e.target.value),onKeyDown:e=>{e.key===`Enter`&&(e.preventDefault(),D()),e.key===`Escape`&&(e.preventDefault(),v())},placeholder:`Search chats and projects`}),(0,m.jsx)(`kbd`,{children:`Esc`})]}),(0,m.jsxs)(`div`,{className:`command-results`,children:[(0,m.jsxs)(`button`,{className:`command-result command-create`,onClick:x,children:[(0,m.jsx)(f,{size:15}),(0,m.jsx)(`span`,{children:`New local task`}),(0,m.jsx)(`small`,{children:`General`})]}),(0,m.jsxs)(b,{label:`Projects`,children:[E.map(e=>(0,m.jsxs)(`button`,{className:`command-result`,onClick:()=>S(e),children:[i(e)?(0,m.jsx)(d,{size:15}):(0,m.jsx)(u,{size:15}),(0,m.jsx)(`span`,{children:e.project.name}),(0,m.jsx)(`small`,{children:y(e)})]},e.project.id)),E.length===0&&(0,m.jsx)(`div`,{className:`command-empty`,children:`No projects found`})]}),(0,m.jsxs)(b,{label:`Chats`,children:[T.map(e=>(0,m.jsxs)(`button`,{className:`command-result`,onClick:()=>C(e),children:[e.pinned?(0,m.jsx)(l,{size:15}):e.savedForLater?(0,m.jsx)(s,{size:15}):(0,m.jsx)(a,{size:15}),(0,m.jsx)(`span`,{children:e.title}),(0,m.jsx)(`small`,{children:e.appName??o(e.updatedAt)})]},e.id)),T.length===0&&(0,m.jsx)(`div`,{className:`command-empty`,children:`No chats found`})]})]})]})})}function g(e,t,n){let r=[];for(let i of e)if((!t||`${i.title} ${i.appName??``}`.toLowerCase().includes(t))&&(r.push(i),r.length>=n))break;return r}function _(e,t,n){let r=[];for(let i of e)if((!t||v(i).toLowerCase().includes(t))&&(r.push(i),r.length>=n))break;return r}function v(e){return r(e)?`${e.project.name} ${e.project.path} ${e.project.workspacePath}`:`${e.project.name} ${e.project.sourceLabel??``} ${e.project.organizationName??``}`}function y(e){return i(e)?e.project.organizationName??`Cloud Project`:e.project.linkedOpenPondApp?`OpenPond project`:e.project.source===`git`?`Local Git`:`Local folder`}function b({label:e,children:t}){return(0,m.jsxs)(`div`,{className:`command-group`,children:[(0,m.jsx)(`div`,{className:`command-group-label`,children:e}),t]})}export{h as CommandMenu};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{i as e}from"./rolldown-runtime-Dd_uD5pT.js";import{g as t,m as n}from"./index-CDtTBysF.js";import{o as r,r as i,t as a}from"./ComposerAttachments-C_K_05H9.js";import"./icons-CYvTltSH.js";import{F as o,x as s}from"./training-model-data-vvvphDlO.js";import{i as c,n as l,r as u,t as d}from"./wifi-off-DWtVm7W7.js";import{t as f}from"./paperclip-DYZEL_Gi.js";import{t as p}from"./refresh-cw-Cx_7Zlbl.js";import{t as m}from"./x-EG07vYCF.js";import{r as h}from"./AppToastContext-D7z0w1PS.js";import{Gt as g,Kt as _,qt as v}from"./App-CV1p0_Zy.js";import{Gt as y,Ht as b,wt as x}from"./MainPane-BtzUF6O_.js";var S=e(t(),1),C=n(),w=2e4,T=10,E=12582912,D=new Set([`image/png`,`image/jpeg`,`image/webp`,`image/gif`]);function O(e){let[t,n]=(0,S.useState)(``),[o,s]=(0,S.useState)(0),[c,l]=(0,S.useState)([]),[u,d]=(0,S.useState)(null),[p,h]=(0,S.useState)(!1),[_,v]=(0,S.useState)([]),[b,O]=(0,S.useState)(0),[N,P]=(0,S.useState)(null),F=(0,S.useRef)(null),I=(0,S.useRef)(null),L=(0,S.useRef)(c);L.current=c;let R=(0,S.useMemo)(()=>k(t,o),[t,o]),z=R?`${R.start}:${R.end}:${R.query}`:null,B=R?.query??null,V=(0,S.useMemo)(()=>{if(!R)return[];let t=new Map;for(let n of[...e.members,..._])t.set(n.userId,n);let n=R.query.toLowerCase();return[...t.values()].filter(e=>`${e.handle??``} ${e.name??``}`.toLowerCase().includes(n)).slice(0,8)},[R,e.members,_]),H=!!(R&&z!==N&&V.length>0),U=!!(e.disabled||e.busy||p),W=!U&&(!!t.trim()||c.length>0);(0,S.useEffect)(()=>{if(B==null){v([]);return}let t=!0,n=window.setTimeout(()=>{e.onSearchMembers(B).then(e=>{t&&v(e)},()=>{t&&v([])})},150);return()=>{t=!1,window.clearTimeout(n)}},[B,e.onSearchMembers]),(0,S.useEffect)(()=>{O(0)},[z]),(0,S.useEffect)(()=>()=>M(L.current),[]);async function G(i){if(i?.preventDefault(),W){d(null),h(!0);try{let i=await Promise.all(c.map(r));if(!await e.onSend({body:t,mentionUserIds:A(t,e.members),attachments:i,replyToMessageId:e.replyTo?.id??null}))return;M(c),n(``),s(0),l([]),e.onCancelReply()}catch(e){d(e instanceof Error?e.message:String(e))}finally{h(!1)}}}function K(e){if(H){if(e.key===`ArrowDown`){e.preventDefault(),O(e=>(e+1)%V.length);return}if(e.key===`ArrowUp`){e.preventDefault(),O(e=>(e-1+V.length)%V.length);return}if(e.key===`Enter`||e.key===`Tab`){e.preventDefault(),X(V[b]??V[0]);return}if(e.key===`Escape`){e.preventDefault(),P(z);return}}e.key!==`Enter`||e.shiftKey||e.nativeEvent.isComposing||(e.preventDefault(),G())}function q(e){if(!e)return;d(null);let t=Math.max(0,T-c.length);if(t===0){d(`You can attach up to ${T} images.`),Y();return}let n=[...e],r=n.slice(0,t),a=r.find(e=>!D.has(e.type)),o=r.find(e=>e.size<=0||e.size>E);if(a){d(`${a.name} is not a supported image type.`),Y();return}if(o){d(`${o.name} must be smaller than 12 MB.`),Y();return}let s=r.map(e=>({id:i(),file:e,name:e.name,mediaType:e.type,sizeBytes:e.size,kind:`image`,previewUrl:URL.createObjectURL(e)}));l(e=>[...e,...s]),n.length>t&&d(`Only ${T} images can be attached to one message.`),Y()}function J(e){l(t=>{let n=t.find(t=>t.id===e);return n?.previewUrl&&URL.revokeObjectURL(n.previewUrl),t.filter(t=>t.id!==e)})}function Y(){F.current&&(F.current.value=``)}function X(e){if(!R)return;let r=`@${j(e)} `,i=`${t.slice(0,R.start)}${r}${t.slice(R.end)}`,a=R.start+r.length;n(i),s(a),P(null),window.requestAnimationFrame(()=>I.current?.focusAtPromptIndex(a))}return(0,C.jsxs)(`form`,{className:`composer dock community-composer${c.length>0?` has-attachments`:``}${u?` has-attachment-error`:``}`,onSubmit:G,children:[e.replyTo?(0,C.jsxs)(`div`,{className:`community-composer-reply`,children:[(0,C.jsxs)(`span`,{children:[(0,C.jsx)(`strong`,{children:`Replying to`}),e.replyTo.body.slice(0,100)||`message`]}),(0,C.jsx)(`button`,{type:`button`,"aria-label":`Cancel reply`,onClick:e.onCancelReply,children:(0,C.jsx)(m,{size:13})})]}):null,H?(0,C.jsx)(`div`,{className:`community-mention-menu`,role:`listbox`,"aria-label":`Community members`,children:V.map((e,t)=>(0,C.jsxs)(`button`,{type:`button`,role:`option`,"aria-selected":t===b,onMouseDown:e=>e.preventDefault(),onClick:()=>X(e),children:[(0,C.jsx)(`strong`,{children:e.name??e.handle??`Community member`}),e.handle?(0,C.jsxs)(`small`,{children:[`@`,e.handle]}):null]},e.userId))}):null,(0,C.jsxs)(`div`,{className:`composer-input-shell`,children:[c.length>0?(0,C.jsx)(`div`,{className:`composer-attachments`,"aria-label":`Selected attachments`,children:c.map(e=>(0,C.jsx)(a,{attachment:e,onRemove:()=>J(e.id)},e.id))}):null,u?(0,C.jsx)(g,{error:u}):null,(0,C.jsx)(`div`,{className:`composer-textarea-frame`,onClick:e=>{e.target===e.currentTarget&&I.current?.focusAtPromptIndex(o)},children:(0,C.jsx)(x,{ref:I,disabled:U,onCursorChange:s,onKeyDown:K,onPromptChange:(e,t)=>{let r=e.slice(0,w);n(r),s(Math.min(t,r.length))},onTokenPositionChange:()=>void 0,placeholder:e.disabled?`Accept the community rules to post`:`Message community`,prompt:t,token:null})}),(0,C.jsxs)(`div`,{className:`composer-primary-controls team-chat-composer-controls`,children:[(0,C.jsx)(`input`,{ref:F,className:`composer-file-input`,hidden:!0,type:`file`,accept:`image/png,image/jpeg,image/webp,image/gif`,multiple:!0,onChange:e=>q(e.currentTarget.files)}),(0,C.jsx)(`button`,{type:`button`,className:`composer-icon`,"aria-label":`Attach images`,disabled:U||c.length>=T,onClick:()=>F.current?.click(),children:(0,C.jsx)(f,{size:17})}),(0,C.jsx)(`div`,{className:`composer-spacer`}),(0,C.jsx)(`button`,{type:`submit`,className:`send-button`,"aria-label":`Send message`,disabled:!W,children:(0,C.jsx)(y,{size:17})})]})]})]})}function k(e,t=e.length){let n=Math.max(0,Math.min(t,e.length)),r=/(?:^|\s)@([\w-]*)$/.exec(e.slice(0,n));return!r||r.index==null?null:{start:r.index+r[0].indexOf(`@`),end:n,query:r[1]??``}}function A(e,t){let n=new Set([...e.matchAll(/(?:^|\s)@([\w-]+)/g)].map(e=>e[1]?.toLowerCase()));return t.filter(e=>n.has(j(e).toLowerCase())).map(e=>e.userId)}function j(e){return e.handle??e.name?.replace(/[^\w-]/g,``)??e.userId}function M(e){for(let t of e)t.previewUrl&&URL.revokeObjectURL(t.previewUrl)}function N(e){let[t,n]=(0,S.useState)(!1),[r,i]=(0,S.useState)(e.message.body),a=e.message.refs.find(e=>e.refType===`message_reply`),c=a?e.messagesById.get(a.refId)??null:null,l=c?.authorUserId?e.membersById.get(c.authorUserId)??null:null;return(0,C.jsxs)(`article`,{className:`community-message${e.own?` own`:``}`,id:`community-message-${e.message.id}`,children:[(0,C.jsx)(`div`,{className:`community-avatar`,children:P(e.author?.name??e.author?.handle??`?`)}),(0,C.jsxs)(`div`,{className:`community-message-content`,children:[(0,C.jsxs)(`header`,{children:[(0,C.jsx)(`strong`,{children:e.author?.name??e.author?.handle??`Community member`}),(0,C.jsx)(`time`,{dateTime:e.message.createdAt,children:F(e.message.createdAt)}),e.message.editedAt?(0,C.jsx)(`span`,{children:`edited`}):null,e.message.deletedAt?null:(0,C.jsxs)(`div`,{className:`community-message-actions`,children:[(0,C.jsx)(`button`,{type:`button`,"aria-label":`Reply`,onClick:()=>e.onReply(e.message),children:(0,C.jsx)(b,{size:13})}),e.own?(0,C.jsx)(`button`,{type:`button`,"aria-label":`Edit`,onClick:()=>n(!0),children:(0,C.jsx)(v,{size:13})}):null,e.own?(0,C.jsx)(`button`,{type:`button`,"aria-label":`Delete`,onClick:()=>void e.onDelete(e.message.id),children:(0,C.jsx)(o,{size:13})}):null]})]}),a?(0,C.jsxs)(`button`,{type:`button`,className:`community-reply-quote`,onClick:()=>document.getElementById(`community-message-${a.refId}`)?.scrollIntoView({behavior:`smooth`,block:`center`}),children:[(0,C.jsx)(`strong`,{children:l?.name??`Community member`}),(0,C.jsx)(`span`,{children:c?.deletedAt?`Message deleted`:c?.body??String(a.preview.body??`Earlier message`)})]}):null,t?(0,C.jsxs)(`form`,{className:`community-message-edit`,onSubmit:t=>{t.preventDefault(),e.onEdit(e.message.id,r).then(e=>{e&&n(!1)})},children:[(0,C.jsx)(`textarea`,{autoFocus:!0,value:r,onChange:e=>i(e.currentTarget.value)}),(0,C.jsxs)(`div`,{children:[(0,C.jsx)(`button`,{type:`button`,onClick:()=>n(!1),children:`Cancel`}),(0,C.jsx)(`button`,{type:`submit`,disabled:!r.trim(),children:`Save`})]})]}):e.message.deletedAt?(0,C.jsx)(`div`,{className:`community-message-deleted`,children:`Message deleted`}):(0,C.jsx)(s,{content:e.message.body}),!e.message.deletedAt&&e.message.attachments.length>0?(0,C.jsx)(`div`,{className:`community-message-attachments`,children:e.message.attachments.map(t=>e.attachmentsAccessible?(0,C.jsxs)(`button`,{type:`button`,onClick:()=>void e.onDownloadAttachment(t.id),children:[(0,C.jsx)(`span`,{children:t.name}),(0,C.jsx)(`small`,{children:I(t.sizeBytes)})]},t.id):(0,C.jsxs)(`div`,{className:`community-attachment-placeholder`,children:[(0,C.jsx)(`span`,{children:t.name}),(0,C.jsxs)(`small`,{children:[`Join to view · `,I(t.sizeBytes)]})]},t.id))}):null]})]})}function P(e){return e.split(/\s+/).slice(0,2).map(e=>e[0]?.toUpperCase()??``).join(``)||`?`}function F(e){let t=new Date(e);return Number.isNaN(t.getTime())?``:t.toLocaleTimeString([],{hour:`numeric`,minute:`2-digit`})}function I(e){return e<1024?`${e} B`:e<1048576?`${Math.round(e/1024)} KB`:`${(e/1024/1024).toFixed(1)} MB`}function L(e){let[t,n]=(0,S.useState)(!1),r=(0,S.useRef)(null),i=(0,S.useRef)(e.onClose);(0,S.useEffect)(()=>n(!1),[e.rules.id]),(0,S.useEffect)(()=>{i.current=e.onClose},[e.onClose]),(0,S.useEffect)(()=>{let e=document.activeElement instanceof HTMLElement?document.activeElement:null,t=r.current,n=()=>[...t?.querySelectorAll(`button:not([disabled]), input:not([disabled]), [href], [tabindex]:not([tabindex="-1"])`)??[]];n()[0]?.focus();let a=e=>{if(e.key===`Escape`){e.preventDefault(),i.current();return}if(e.key!==`Tab`)return;let r=n();if(r.length===0){e.preventDefault(),t?.focus();return}let a=r[0],o=r.at(-1);e.shiftKey&&document.activeElement===a?(e.preventDefault(),o.focus()):!e.shiftKey&&document.activeElement===o&&(e.preventDefault(),a.focus())};return document.addEventListener(`keydown`,a),()=>{document.removeEventListener(`keydown`,a),e?.focus()}},[]);let a=e.mode!==`review`;return(0,C.jsx)(`div`,{className:`community-dialog-backdrop`,role:`presentation`,onMouseDown:e.onClose,children:(0,C.jsxs)(`section`,{ref:r,className:`community-rules-dialog`,role:`dialog`,"aria-modal":`true`,"aria-labelledby":`community-rules-title`,tabIndex:-1,onMouseDown:e=>e.stopPropagation(),children:[(0,C.jsxs)(`header`,{children:[(0,C.jsxs)(`div`,{children:[(0,C.jsxs)(`small`,{children:[`Community rules · version `,e.rules.version]}),(0,C.jsx)(`h2`,{id:`community-rules-title`,children:e.rules.title})]}),(0,C.jsx)(`button`,{type:`button`,"aria-label":`Close rules`,onClick:e.onClose,children:(0,C.jsx)(m,{size:16})})]}),(0,C.jsx)(`div`,{className:`community-rules-body`,children:(0,C.jsx)(s,{content:e.rules.bodyMarkdown})}),(0,C.jsxs)(`footer`,{children:[a?(0,C.jsxs)(`label`,{className:`community-rules-acceptance`,children:[(0,C.jsx)(`input`,{type:`checkbox`,checked:t,onChange:e=>n(e.currentTarget.checked)}),(0,C.jsx)(`span`,{children:`I have read and agree to follow these rules.`})]}):(0,C.jsx)(`span`,{}),(0,C.jsxs)(`div`,{children:[(0,C.jsx)(`button`,{type:`button`,className:`secondary`,onClick:e.onClose,children:`Cancel`}),a?(0,C.jsx)(`button`,{type:`button`,disabled:!t||e.busy,onClick:()=>void e.onAccept().then(t=>{t&&e.onClose()}),children:e.busy?`Saving…`:e.mode===`join`?`Agree and join`:`Accept updated rules`}):null]})]})]})})}function R({communities:e,chat:t,currentUserId:n}){h(e.discoveryError),h(t.lostMembership?`Your membership changed. Refresh the community before continuing.`:null),h(e.previewError),h(e.membershipError?.message),h(t.channelsError,{prefix:`Channels`}),h(t.messagesError,{prefix:`Messages`}),h(t.actionError);let[r,i]=(0,S.useState)(null),[a,o]=(0,S.useState)(null),s=(0,S.useRef)(null),c=e.preview,u=c?.membership?.status===`active`,f=!!c?.capabilities.requiresRulesAcceptance,m=(0,S.useMemo)(()=>new Map(t.members.map(e=>[e.userId,e])),[t.members]),g=(0,S.useMemo)(()=>new Map(t.messages.map(e=>[e.id,e])),[t.messages]),v=t.messages.at(-1)?.sequence??0;if((0,S.useEffect)(()=>{let e=s.current;e&&(e.scrollTop=e.scrollHeight)},[t.selectedChannelId,v]),(0,S.useEffect)(()=>{o(null),f&&c?.currentRules&&i(`reaccept`)},[c?.currentRules,f]),!e.selectedSummary)return(0,C.jsx)(`section`,{className:`community-empty-page`,children:(0,C.jsxs)(`div`,{className:`community-discovery-card`,children:[(0,C.jsx)(_,{size:30}),(0,C.jsx)(`h1`,{children:`Discover communities`}),(0,C.jsx)(`p`,{children:e.discoveryLoading&&e.items.length===0?`Finding communities…`:`Preview public conversations and join after accepting each community's rules.`}),e.items.length>0?(0,C.jsx)(`div`,{className:`community-discovery-list`,children:e.items.map(t=>(0,C.jsxs)(`button`,{type:`button`,onClick:()=>e.selectCommunity(t.id),children:[(0,C.jsx)(B,{name:t.displayName,imageUrl:t.imageUrl}),(0,C.jsxs)(`span`,{children:[(0,C.jsx)(`strong`,{children:t.displayName}),(0,C.jsx)(`small`,{children:t.description})]}),(0,C.jsx)(`em`,{children:t.membership?.status===`active`?`Joined`:t.featuredAt?`Featured`:`${t.memberCount.toLocaleString()} members`})]},t.id))}):e.discoveryLoading?null:(0,C.jsx)(`div`,{className:`community-state`,children:`No public communities are available yet.`}),(0,C.jsxs)(`div`,{className:`community-discovery-actions`,children:[(0,C.jsxs)(`button`,{type:`button`,onClick:()=>void e.refresh(),disabled:e.discoveryLoading,children:[(0,C.jsx)(p,{size:14}),` Refresh`]}),e.nextCursor?(0,C.jsx)(`button`,{type:`button`,className:`secondary`,onClick:()=>void e.loadMore(),disabled:e.discoveryLoading,children:`Load more`}):null]})]})});if(!c&&e.previewLoading)return(0,C.jsx)(`section`,{className:`community-empty-page`,children:(0,C.jsxs)(`div`,{className:`community-empty-card`,children:[(0,C.jsx)(`span`,{className:`community-spinner`}),` Loading community…`]})});if(!c)return(0,C.jsx)(`section`,{className:`community-empty-page`,children:(0,C.jsxs)(`div`,{className:`community-empty-card`,children:[(0,C.jsx)(`h1`,{children:e.selectedSummary.displayName}),(0,C.jsx)(`div`,{className:`community-state`,children:`This community preview is unavailable.`}),(0,C.jsxs)(`button`,{type:`button`,onClick:()=>e.selectCommunity(e.selectedSummary.id),children:[(0,C.jsx)(p,{size:14}),` Retry preview`]})]})});let y=c.currentRules;return(0,C.jsxs)(`section`,{className:`community-view`,children:[(0,C.jsxs)(`header`,{className:`community-header`,children:[(0,C.jsxs)(`div`,{className:`community-heading`,children:[(0,C.jsx)(B,{name:c.displayName,imageUrl:c.imageUrl}),(0,C.jsxs)(`div`,{children:[(0,C.jsx)(`small`,{children:c.displayName}),(0,C.jsx)(`h1`,{children:t.selectedChannel?`# ${t.selectedChannel.displayName}`:c.displayName}),(0,C.jsx)(`p`,{children:t.selectedChannel?.topic||c.description})]})]}),(0,C.jsxs)(`div`,{className:`community-header-actions`,children:[(0,C.jsxs)(`span`,{className:`community-member-count`,children:[(0,C.jsx)(_,{size:14}),` `,c.memberCount.toLocaleString()]}),y?(0,C.jsxs)(`button`,{type:`button`,className:`secondary`,onClick:()=>i(`review`),children:[(0,C.jsx)(l,{size:14}),` Rules`]}):null,u?(0,C.jsx)(z,{mode:c.membership?.notificationMode??`mentions`,busy:e.membershipBusy,onMode:e.updateNotifications,onLeave:e.leave}):null]})]}),(0,C.jsxs)(`div`,{className:`community-chat-main conversation-surface-main`,children:[(0,C.jsxs)(`div`,{className:`community-chat-notices`,children:[u?f?(0,C.jsxs)(`div`,{className:`community-preview-banner warning`,children:[(0,C.jsxs)(`div`,{children:[(0,C.jsx)(`strong`,{children:`The rules have changed`}),(0,C.jsx)(`span`,{children:`Accept the current rules to continue reading live updates and posting.`})]}),(0,C.jsx)(`button`,{type:`button`,disabled:!y||e.membershipBusy,onClick:()=>i(`reaccept`),children:`Review updated rules`})]}):null:(0,C.jsxs)(`div`,{className:`community-preview-banner`,children:[(0,C.jsxs)(`div`,{children:[(0,C.jsxs)(`strong`,{children:[`Previewing `,c.displayName]}),(0,C.jsx)(`span`,{children:`Read the public conversation, then accept the rules to join and post.`})]}),(0,C.jsx)(`button`,{type:`button`,disabled:!y||e.membershipBusy,onClick:()=>i(`join`),children:`Join community`})]}),t.realtimeError&&u&&!f?(0,C.jsxs)(`div`,{className:`community-realtime-state`,children:[(0,C.jsx)(d,{size:14}),(0,C.jsx)(`span`,{children:`Live updates are reconnecting. Loaded messages are still available.`})]}):null,t.channelsError?(0,C.jsx)(`button`,{type:`button`,className:`community-state`,onClick:()=>void t.loadChannels(),children:`Retry loading channels`}):null]}),(0,C.jsxs)(`div`,{className:`community-message-pane conversation-message-scroll`,ref:s,role:`log`,"aria-live":`polite`,"aria-relevant":`additions text`,"aria-busy":t.messagesLoading,"aria-label":t.selectedChannel?`${c.displayName}, ${t.selectedChannel.displayName}`:c.displayName,tabIndex:0,children:[t.hasMoreBefore?(0,C.jsx)(`button`,{type:`button`,className:`community-load-older`,disabled:t.olderMessagesLoading,onClick:()=>void t.loadOlder(),children:t.olderMessagesLoading?`Loading…`:`Load earlier messages`}):null,t.messagesLoading&&t.messages.length===0?(0,C.jsx)(`div`,{className:`community-message-state`,children:`Loading messages…`}):null,t.messagesError?(0,C.jsxs)(`div`,{className:`community-message-state`,children:[`Messages are unavailable. `,(0,C.jsx)(`button`,{type:`button`,onClick:()=>void t.loadMessages(),children:`Retry`})]}):null,!t.messagesLoading&&!t.messagesError&&t.messages.length===0?(0,C.jsx)(`div`,{className:`community-message-state`,children:`No messages in this channel yet.`}):null,t.messages.map(e=>(0,C.jsx)(N,{message:e,author:e.authorUserId?m.get(e.authorUserId)??null:null,own:e.authorUserId===n,attachmentsAccessible:!t.previewMode,membersById:m,messagesById:g,onReply:o,onEdit:t.editMessage,onDelete:t.deleteMessage,onDownloadAttachment:t.downloadAttachment},e.id))]}),u?(0,C.jsxs)(`div`,{className:`community-composer-wrap conversation-composer-shell`,children:[t.failedSend?(0,C.jsxs)(`div`,{className:`community-failed-send`,children:[(0,C.jsx)(`span`,{children:`Message not sent.`}),(0,C.jsx)(`button`,{type:`button`,disabled:t.sending,onClick:()=>void t.retrySend(),children:`Retry`}),(0,C.jsx)(`button`,{type:`button`,onClick:t.dismissFailedSend,children:`Dismiss`})]}):null,(0,C.jsx)(O,{members:t.members,replyTo:a,busy:t.sending,disabled:f||t.lostMembership||!t.selectedChannel||t.selectedChannel.postingPolicy===`admins`&&c.membership?.role===`member`,onCancelReply:()=>o(null),onSearchMembers:t.searchMembers,onSend:t.sendMessage})]}):null]}),r&&y?(0,C.jsx)(L,{rules:y,mode:r,busy:e.membershipBusy,onAccept:r===`join`?e.join:e.acceptRules,onClose:()=>i(null)}):null]})}function z(e){let[t,n]=(0,S.useState)(!1);return(0,C.jsxs)(`div`,{className:`community-membership-menu`,children:[(0,C.jsxs)(`button`,{type:`button`,className:`secondary`,"aria-expanded":t,onClick:()=>n(e=>!e),children:[e.mode===`none`?(0,C.jsx)(u,{size:14}):(0,C.jsx)(c,{size:14}),` Joined`]}),t?(0,C.jsxs)(`div`,{className:`community-membership-popover`,children:[(0,C.jsx)(`strong`,{children:`Notifications`}),[`mentions`,`all`,`none`].map(t=>(0,C.jsxs)(`label`,{children:[(0,C.jsx)(`input`,{type:`radio`,name:`community-notifications`,checked:e.mode===t,disabled:e.busy,onChange:()=>void e.onMode(t)}),` `,t===`mentions`?`Mentions`:t===`all`?`All messages`:`Nothing`]},t)),(0,C.jsx)(`button`,{type:`button`,className:`danger`,disabled:e.busy,onClick:()=>{window.confirm(`Leave this community? You can join again later by accepting the current rules.`)&&e.onLeave().then(e=>{e&&n(!1)})},children:`Leave community`})]}):null]})}function B({name:e,imageUrl:t}){return t?(0,C.jsx)(`img`,{className:`community-icon`,src:t,alt:``}):(0,C.jsx)(`span`,{className:`community-icon fallback`,children:e.slice(0,2).toUpperCase()})}export{R as CommunityView};
|
|
1
|
+
import{i as e}from"./rolldown-runtime-Dd_uD5pT.js";import{g as t,m as n}from"./index-DG0kf1wK.js";import{o as r,r as i,t as a}from"./ComposerAttachments-BOyEXVhV.js";import"./icons-nr5d1kC-.js";import{F as o,x as s}from"./training-model-data-CilS0W2N.js";import{i as c,n as l,r as u,t as d}from"./wifi-off-C-GF_rPd.js";import{t as f}from"./paperclip-CNTReC0m.js";import{t as p}from"./refresh-cw-avBifyns.js";import{t as m}from"./x-CQ0pGF6Q.js";import{r as h}from"./AppToastContext-DyaZYQXu.js";import{Gt as g,Kt as _,qt as v}from"./App-CqqK4NLa.js";import{Gt as y,Ht as b,wt as x}from"./MainPane-aEELnEKb.js";var S=e(t(),1),C=n(),w=2e4,T=10,E=12582912,D=new Set([`image/png`,`image/jpeg`,`image/webp`,`image/gif`]);function O(e){let[t,n]=(0,S.useState)(``),[o,s]=(0,S.useState)(0),[c,l]=(0,S.useState)([]),[u,d]=(0,S.useState)(null),[p,h]=(0,S.useState)(!1),[_,v]=(0,S.useState)([]),[b,O]=(0,S.useState)(0),[N,P]=(0,S.useState)(null),F=(0,S.useRef)(null),I=(0,S.useRef)(null),L=(0,S.useRef)(c);L.current=c;let R=(0,S.useMemo)(()=>k(t,o),[t,o]),z=R?`${R.start}:${R.end}:${R.query}`:null,B=R?.query??null,V=(0,S.useMemo)(()=>{if(!R)return[];let t=new Map;for(let n of[...e.members,..._])t.set(n.userId,n);let n=R.query.toLowerCase();return[...t.values()].filter(e=>`${e.handle??``} ${e.name??``}`.toLowerCase().includes(n)).slice(0,8)},[R,e.members,_]),H=!!(R&&z!==N&&V.length>0),U=!!(e.disabled||e.busy||p),W=!U&&(!!t.trim()||c.length>0);(0,S.useEffect)(()=>{if(B==null){v([]);return}let t=!0,n=window.setTimeout(()=>{e.onSearchMembers(B).then(e=>{t&&v(e)},()=>{t&&v([])})},150);return()=>{t=!1,window.clearTimeout(n)}},[B,e.onSearchMembers]),(0,S.useEffect)(()=>{O(0)},[z]),(0,S.useEffect)(()=>()=>M(L.current),[]);async function G(i){if(i?.preventDefault(),W){d(null),h(!0);try{let i=await Promise.all(c.map(r));if(!await e.onSend({body:t,mentionUserIds:A(t,e.members),attachments:i,replyToMessageId:e.replyTo?.id??null}))return;M(c),n(``),s(0),l([]),e.onCancelReply()}catch(e){d(e instanceof Error?e.message:String(e))}finally{h(!1)}}}function K(e){if(H){if(e.key===`ArrowDown`){e.preventDefault(),O(e=>(e+1)%V.length);return}if(e.key===`ArrowUp`){e.preventDefault(),O(e=>(e-1+V.length)%V.length);return}if(e.key===`Enter`||e.key===`Tab`){e.preventDefault(),X(V[b]??V[0]);return}if(e.key===`Escape`){e.preventDefault(),P(z);return}}e.key!==`Enter`||e.shiftKey||e.nativeEvent.isComposing||(e.preventDefault(),G())}function q(e){if(!e)return;d(null);let t=Math.max(0,T-c.length);if(t===0){d(`You can attach up to ${T} images.`),Y();return}let n=[...e],r=n.slice(0,t),a=r.find(e=>!D.has(e.type)),o=r.find(e=>e.size<=0||e.size>E);if(a){d(`${a.name} is not a supported image type.`),Y();return}if(o){d(`${o.name} must be smaller than 12 MB.`),Y();return}let s=r.map(e=>({id:i(),file:e,name:e.name,mediaType:e.type,sizeBytes:e.size,kind:`image`,previewUrl:URL.createObjectURL(e)}));l(e=>[...e,...s]),n.length>t&&d(`Only ${T} images can be attached to one message.`),Y()}function J(e){l(t=>{let n=t.find(t=>t.id===e);return n?.previewUrl&&URL.revokeObjectURL(n.previewUrl),t.filter(t=>t.id!==e)})}function Y(){F.current&&(F.current.value=``)}function X(e){if(!R)return;let r=`@${j(e)} `,i=`${t.slice(0,R.start)}${r}${t.slice(R.end)}`,a=R.start+r.length;n(i),s(a),P(null),window.requestAnimationFrame(()=>I.current?.focusAtPromptIndex(a))}return(0,C.jsxs)(`form`,{className:`composer dock community-composer${c.length>0?` has-attachments`:``}${u?` has-attachment-error`:``}`,onSubmit:G,children:[e.replyTo?(0,C.jsxs)(`div`,{className:`community-composer-reply`,children:[(0,C.jsxs)(`span`,{children:[(0,C.jsx)(`strong`,{children:`Replying to`}),e.replyTo.body.slice(0,100)||`message`]}),(0,C.jsx)(`button`,{type:`button`,"aria-label":`Cancel reply`,onClick:e.onCancelReply,children:(0,C.jsx)(m,{size:13})})]}):null,H?(0,C.jsx)(`div`,{className:`community-mention-menu`,role:`listbox`,"aria-label":`Community members`,children:V.map((e,t)=>(0,C.jsxs)(`button`,{type:`button`,role:`option`,"aria-selected":t===b,onMouseDown:e=>e.preventDefault(),onClick:()=>X(e),children:[(0,C.jsx)(`strong`,{children:e.name??e.handle??`Community member`}),e.handle?(0,C.jsxs)(`small`,{children:[`@`,e.handle]}):null]},e.userId))}):null,(0,C.jsxs)(`div`,{className:`composer-input-shell`,children:[c.length>0?(0,C.jsx)(`div`,{className:`composer-attachments`,"aria-label":`Selected attachments`,children:c.map(e=>(0,C.jsx)(a,{attachment:e,onRemove:()=>J(e.id)},e.id))}):null,u?(0,C.jsx)(g,{error:u}):null,(0,C.jsx)(`div`,{className:`composer-textarea-frame`,onClick:e=>{e.target===e.currentTarget&&I.current?.focusAtPromptIndex(o)},children:(0,C.jsx)(x,{ref:I,disabled:U,onCursorChange:s,onKeyDown:K,onPromptChange:(e,t)=>{let r=e.slice(0,w);n(r),s(Math.min(t,r.length))},onTokenPositionChange:()=>void 0,placeholder:e.disabled?`Accept the community rules to post`:`Message community`,prompt:t,token:null})}),(0,C.jsxs)(`div`,{className:`composer-primary-controls team-chat-composer-controls`,children:[(0,C.jsx)(`input`,{ref:F,className:`composer-file-input`,hidden:!0,type:`file`,accept:`image/png,image/jpeg,image/webp,image/gif`,multiple:!0,onChange:e=>q(e.currentTarget.files)}),(0,C.jsx)(`button`,{type:`button`,className:`composer-icon`,"aria-label":`Attach images`,disabled:U||c.length>=T,onClick:()=>F.current?.click(),children:(0,C.jsx)(f,{size:17})}),(0,C.jsx)(`div`,{className:`composer-spacer`}),(0,C.jsx)(`button`,{type:`submit`,className:`send-button`,"aria-label":`Send message`,disabled:!W,children:(0,C.jsx)(y,{size:17})})]})]})]})}function k(e,t=e.length){let n=Math.max(0,Math.min(t,e.length)),r=/(?:^|\s)@([\w-]*)$/.exec(e.slice(0,n));return!r||r.index==null?null:{start:r.index+r[0].indexOf(`@`),end:n,query:r[1]??``}}function A(e,t){let n=new Set([...e.matchAll(/(?:^|\s)@([\w-]+)/g)].map(e=>e[1]?.toLowerCase()));return t.filter(e=>n.has(j(e).toLowerCase())).map(e=>e.userId)}function j(e){return e.handle??e.name?.replace(/[^\w-]/g,``)??e.userId}function M(e){for(let t of e)t.previewUrl&&URL.revokeObjectURL(t.previewUrl)}function N(e){let[t,n]=(0,S.useState)(!1),[r,i]=(0,S.useState)(e.message.body),a=e.message.refs.find(e=>e.refType===`message_reply`),c=a?e.messagesById.get(a.refId)??null:null,l=c?.authorUserId?e.membersById.get(c.authorUserId)??null:null;return(0,C.jsxs)(`article`,{className:`community-message${e.own?` own`:``}`,id:`community-message-${e.message.id}`,children:[(0,C.jsx)(`div`,{className:`community-avatar`,children:P(e.author?.name??e.author?.handle??`?`)}),(0,C.jsxs)(`div`,{className:`community-message-content`,children:[(0,C.jsxs)(`header`,{children:[(0,C.jsx)(`strong`,{children:e.author?.name??e.author?.handle??`Community member`}),(0,C.jsx)(`time`,{dateTime:e.message.createdAt,children:F(e.message.createdAt)}),e.message.editedAt?(0,C.jsx)(`span`,{children:`edited`}):null,e.message.deletedAt?null:(0,C.jsxs)(`div`,{className:`community-message-actions`,children:[(0,C.jsx)(`button`,{type:`button`,"aria-label":`Reply`,onClick:()=>e.onReply(e.message),children:(0,C.jsx)(b,{size:13})}),e.own?(0,C.jsx)(`button`,{type:`button`,"aria-label":`Edit`,onClick:()=>n(!0),children:(0,C.jsx)(v,{size:13})}):null,e.own?(0,C.jsx)(`button`,{type:`button`,"aria-label":`Delete`,onClick:()=>void e.onDelete(e.message.id),children:(0,C.jsx)(o,{size:13})}):null]})]}),a?(0,C.jsxs)(`button`,{type:`button`,className:`community-reply-quote`,onClick:()=>document.getElementById(`community-message-${a.refId}`)?.scrollIntoView({behavior:`smooth`,block:`center`}),children:[(0,C.jsx)(`strong`,{children:l?.name??`Community member`}),(0,C.jsx)(`span`,{children:c?.deletedAt?`Message deleted`:c?.body??String(a.preview.body??`Earlier message`)})]}):null,t?(0,C.jsxs)(`form`,{className:`community-message-edit`,onSubmit:t=>{t.preventDefault(),e.onEdit(e.message.id,r).then(e=>{e&&n(!1)})},children:[(0,C.jsx)(`textarea`,{autoFocus:!0,value:r,onChange:e=>i(e.currentTarget.value)}),(0,C.jsxs)(`div`,{children:[(0,C.jsx)(`button`,{type:`button`,onClick:()=>n(!1),children:`Cancel`}),(0,C.jsx)(`button`,{type:`submit`,disabled:!r.trim(),children:`Save`})]})]}):e.message.deletedAt?(0,C.jsx)(`div`,{className:`community-message-deleted`,children:`Message deleted`}):(0,C.jsx)(s,{content:e.message.body}),!e.message.deletedAt&&e.message.attachments.length>0?(0,C.jsx)(`div`,{className:`community-message-attachments`,children:e.message.attachments.map(t=>e.attachmentsAccessible?(0,C.jsxs)(`button`,{type:`button`,onClick:()=>void e.onDownloadAttachment(t.id),children:[(0,C.jsx)(`span`,{children:t.name}),(0,C.jsx)(`small`,{children:I(t.sizeBytes)})]},t.id):(0,C.jsxs)(`div`,{className:`community-attachment-placeholder`,children:[(0,C.jsx)(`span`,{children:t.name}),(0,C.jsxs)(`small`,{children:[`Join to view · `,I(t.sizeBytes)]})]},t.id))}):null]})]})}function P(e){return e.split(/\s+/).slice(0,2).map(e=>e[0]?.toUpperCase()??``).join(``)||`?`}function F(e){let t=new Date(e);return Number.isNaN(t.getTime())?``:t.toLocaleTimeString([],{hour:`numeric`,minute:`2-digit`})}function I(e){return e<1024?`${e} B`:e<1048576?`${Math.round(e/1024)} KB`:`${(e/1024/1024).toFixed(1)} MB`}function L(e){let[t,n]=(0,S.useState)(!1),r=(0,S.useRef)(null),i=(0,S.useRef)(e.onClose);(0,S.useEffect)(()=>n(!1),[e.rules.id]),(0,S.useEffect)(()=>{i.current=e.onClose},[e.onClose]),(0,S.useEffect)(()=>{let e=document.activeElement instanceof HTMLElement?document.activeElement:null,t=r.current,n=()=>[...t?.querySelectorAll(`button:not([disabled]), input:not([disabled]), [href], [tabindex]:not([tabindex="-1"])`)??[]];n()[0]?.focus();let a=e=>{if(e.key===`Escape`){e.preventDefault(),i.current();return}if(e.key!==`Tab`)return;let r=n();if(r.length===0){e.preventDefault(),t?.focus();return}let a=r[0],o=r.at(-1);e.shiftKey&&document.activeElement===a?(e.preventDefault(),o.focus()):!e.shiftKey&&document.activeElement===o&&(e.preventDefault(),a.focus())};return document.addEventListener(`keydown`,a),()=>{document.removeEventListener(`keydown`,a),e?.focus()}},[]);let a=e.mode!==`review`;return(0,C.jsx)(`div`,{className:`community-dialog-backdrop`,role:`presentation`,onMouseDown:e.onClose,children:(0,C.jsxs)(`section`,{ref:r,className:`community-rules-dialog`,role:`dialog`,"aria-modal":`true`,"aria-labelledby":`community-rules-title`,tabIndex:-1,onMouseDown:e=>e.stopPropagation(),children:[(0,C.jsxs)(`header`,{children:[(0,C.jsxs)(`div`,{children:[(0,C.jsxs)(`small`,{children:[`Community rules · version `,e.rules.version]}),(0,C.jsx)(`h2`,{id:`community-rules-title`,children:e.rules.title})]}),(0,C.jsx)(`button`,{type:`button`,"aria-label":`Close rules`,onClick:e.onClose,children:(0,C.jsx)(m,{size:16})})]}),(0,C.jsx)(`div`,{className:`community-rules-body`,children:(0,C.jsx)(s,{content:e.rules.bodyMarkdown})}),(0,C.jsxs)(`footer`,{children:[a?(0,C.jsxs)(`label`,{className:`community-rules-acceptance`,children:[(0,C.jsx)(`input`,{type:`checkbox`,checked:t,onChange:e=>n(e.currentTarget.checked)}),(0,C.jsx)(`span`,{children:`I have read and agree to follow these rules.`})]}):(0,C.jsx)(`span`,{}),(0,C.jsxs)(`div`,{children:[(0,C.jsx)(`button`,{type:`button`,className:`secondary`,onClick:e.onClose,children:`Cancel`}),a?(0,C.jsx)(`button`,{type:`button`,disabled:!t||e.busy,onClick:()=>void e.onAccept().then(t=>{t&&e.onClose()}),children:e.busy?`Saving…`:e.mode===`join`?`Agree and join`:`Accept updated rules`}):null]})]})]})})}function R({communities:e,chat:t,currentUserId:n}){h(e.discoveryError),h(t.lostMembership?`Your membership changed. Refresh the community before continuing.`:null),h(e.previewError),h(e.membershipError?.message),h(t.channelsError,{prefix:`Channels`}),h(t.messagesError,{prefix:`Messages`}),h(t.actionError);let[r,i]=(0,S.useState)(null),[a,o]=(0,S.useState)(null),s=(0,S.useRef)(null),c=e.preview,u=c?.membership?.status===`active`,f=!!c?.capabilities.requiresRulesAcceptance,m=(0,S.useMemo)(()=>new Map(t.members.map(e=>[e.userId,e])),[t.members]),g=(0,S.useMemo)(()=>new Map(t.messages.map(e=>[e.id,e])),[t.messages]),v=t.messages.at(-1)?.sequence??0;if((0,S.useEffect)(()=>{let e=s.current;e&&(e.scrollTop=e.scrollHeight)},[t.selectedChannelId,v]),(0,S.useEffect)(()=>{o(null),f&&c?.currentRules&&i(`reaccept`)},[c?.currentRules,f]),!e.selectedSummary)return(0,C.jsx)(`section`,{className:`community-empty-page`,children:(0,C.jsxs)(`div`,{className:`community-discovery-card`,children:[(0,C.jsx)(_,{size:30}),(0,C.jsx)(`h1`,{children:`Discover communities`}),(0,C.jsx)(`p`,{children:e.discoveryLoading&&e.items.length===0?`Finding communities…`:`Preview public conversations and join after accepting each community's rules.`}),e.items.length>0?(0,C.jsx)(`div`,{className:`community-discovery-list`,children:e.items.map(t=>(0,C.jsxs)(`button`,{type:`button`,onClick:()=>e.selectCommunity(t.id),children:[(0,C.jsx)(B,{name:t.displayName,imageUrl:t.imageUrl}),(0,C.jsxs)(`span`,{children:[(0,C.jsx)(`strong`,{children:t.displayName}),(0,C.jsx)(`small`,{children:t.description})]}),(0,C.jsx)(`em`,{children:t.membership?.status===`active`?`Joined`:t.featuredAt?`Featured`:`${t.memberCount.toLocaleString()} members`})]},t.id))}):e.discoveryLoading?null:(0,C.jsx)(`div`,{className:`community-state`,children:`No public communities are available yet.`}),(0,C.jsxs)(`div`,{className:`community-discovery-actions`,children:[(0,C.jsxs)(`button`,{type:`button`,onClick:()=>void e.refresh(),disabled:e.discoveryLoading,children:[(0,C.jsx)(p,{size:14}),` Refresh`]}),e.nextCursor?(0,C.jsx)(`button`,{type:`button`,className:`secondary`,onClick:()=>void e.loadMore(),disabled:e.discoveryLoading,children:`Load more`}):null]})]})});if(!c&&e.previewLoading)return(0,C.jsx)(`section`,{className:`community-empty-page`,children:(0,C.jsxs)(`div`,{className:`community-empty-card`,children:[(0,C.jsx)(`span`,{className:`community-spinner`}),` Loading community…`]})});if(!c)return(0,C.jsx)(`section`,{className:`community-empty-page`,children:(0,C.jsxs)(`div`,{className:`community-empty-card`,children:[(0,C.jsx)(`h1`,{children:e.selectedSummary.displayName}),(0,C.jsx)(`div`,{className:`community-state`,children:`This community preview is unavailable.`}),(0,C.jsxs)(`button`,{type:`button`,onClick:()=>e.selectCommunity(e.selectedSummary.id),children:[(0,C.jsx)(p,{size:14}),` Retry preview`]})]})});let y=c.currentRules;return(0,C.jsxs)(`section`,{className:`community-view`,children:[(0,C.jsxs)(`header`,{className:`community-header`,children:[(0,C.jsxs)(`div`,{className:`community-heading`,children:[(0,C.jsx)(B,{name:c.displayName,imageUrl:c.imageUrl}),(0,C.jsxs)(`div`,{children:[(0,C.jsx)(`small`,{children:c.displayName}),(0,C.jsx)(`h1`,{children:t.selectedChannel?`# ${t.selectedChannel.displayName}`:c.displayName}),(0,C.jsx)(`p`,{children:t.selectedChannel?.topic||c.description})]})]}),(0,C.jsxs)(`div`,{className:`community-header-actions`,children:[(0,C.jsxs)(`span`,{className:`community-member-count`,children:[(0,C.jsx)(_,{size:14}),` `,c.memberCount.toLocaleString()]}),y?(0,C.jsxs)(`button`,{type:`button`,className:`secondary`,onClick:()=>i(`review`),children:[(0,C.jsx)(l,{size:14}),` Rules`]}):null,u?(0,C.jsx)(z,{mode:c.membership?.notificationMode??`mentions`,busy:e.membershipBusy,onMode:e.updateNotifications,onLeave:e.leave}):null]})]}),(0,C.jsxs)(`div`,{className:`community-chat-main conversation-surface-main`,children:[(0,C.jsxs)(`div`,{className:`community-chat-notices`,children:[u?f?(0,C.jsxs)(`div`,{className:`community-preview-banner warning`,children:[(0,C.jsxs)(`div`,{children:[(0,C.jsx)(`strong`,{children:`The rules have changed`}),(0,C.jsx)(`span`,{children:`Accept the current rules to continue reading live updates and posting.`})]}),(0,C.jsx)(`button`,{type:`button`,disabled:!y||e.membershipBusy,onClick:()=>i(`reaccept`),children:`Review updated rules`})]}):null:(0,C.jsxs)(`div`,{className:`community-preview-banner`,children:[(0,C.jsxs)(`div`,{children:[(0,C.jsxs)(`strong`,{children:[`Previewing `,c.displayName]}),(0,C.jsx)(`span`,{children:`Read the public conversation, then accept the rules to join and post.`})]}),(0,C.jsx)(`button`,{type:`button`,disabled:!y||e.membershipBusy,onClick:()=>i(`join`),children:`Join community`})]}),t.realtimeError&&u&&!f?(0,C.jsxs)(`div`,{className:`community-realtime-state`,children:[(0,C.jsx)(d,{size:14}),(0,C.jsx)(`span`,{children:`Live updates are reconnecting. Loaded messages are still available.`})]}):null,t.channelsError?(0,C.jsx)(`button`,{type:`button`,className:`community-state`,onClick:()=>void t.loadChannels(),children:`Retry loading channels`}):null]}),(0,C.jsxs)(`div`,{className:`community-message-pane conversation-message-scroll`,ref:s,role:`log`,"aria-live":`polite`,"aria-relevant":`additions text`,"aria-busy":t.messagesLoading,"aria-label":t.selectedChannel?`${c.displayName}, ${t.selectedChannel.displayName}`:c.displayName,tabIndex:0,children:[t.hasMoreBefore?(0,C.jsx)(`button`,{type:`button`,className:`community-load-older`,disabled:t.olderMessagesLoading,onClick:()=>void t.loadOlder(),children:t.olderMessagesLoading?`Loading…`:`Load earlier messages`}):null,t.messagesLoading&&t.messages.length===0?(0,C.jsx)(`div`,{className:`community-message-state`,children:`Loading messages…`}):null,t.messagesError?(0,C.jsxs)(`div`,{className:`community-message-state`,children:[`Messages are unavailable. `,(0,C.jsx)(`button`,{type:`button`,onClick:()=>void t.loadMessages(),children:`Retry`})]}):null,!t.messagesLoading&&!t.messagesError&&t.messages.length===0?(0,C.jsx)(`div`,{className:`community-message-state`,children:`No messages in this channel yet.`}):null,t.messages.map(e=>(0,C.jsx)(N,{message:e,author:e.authorUserId?m.get(e.authorUserId)??null:null,own:e.authorUserId===n,attachmentsAccessible:!t.previewMode,membersById:m,messagesById:g,onReply:o,onEdit:t.editMessage,onDelete:t.deleteMessage,onDownloadAttachment:t.downloadAttachment},e.id))]}),u?(0,C.jsxs)(`div`,{className:`community-composer-wrap conversation-composer-shell`,children:[t.failedSend?(0,C.jsxs)(`div`,{className:`community-failed-send`,children:[(0,C.jsx)(`span`,{children:`Message not sent.`}),(0,C.jsx)(`button`,{type:`button`,disabled:t.sending,onClick:()=>void t.retrySend(),children:`Retry`}),(0,C.jsx)(`button`,{type:`button`,onClick:t.dismissFailedSend,children:`Dismiss`})]}):null,(0,C.jsx)(O,{members:t.members,replyTo:a,busy:t.sending,disabled:f||t.lostMembership||!t.selectedChannel||t.selectedChannel.postingPolicy===`admins`&&c.membership?.role===`member`,onCancelReply:()=>o(null),onSearchMembers:t.searchMembers,onSend:t.sendMessage})]}):null]}),r&&y?(0,C.jsx)(L,{rules:y,mode:r,busy:e.membershipBusy,onAccept:r===`join`?e.join:e.acceptRules,onClose:()=>i(null)}):null]})}function z(e){let[t,n]=(0,S.useState)(!1);return(0,C.jsxs)(`div`,{className:`community-membership-menu`,children:[(0,C.jsxs)(`button`,{type:`button`,className:`secondary`,"aria-expanded":t,onClick:()=>n(e=>!e),children:[e.mode===`none`?(0,C.jsx)(u,{size:14}):(0,C.jsx)(c,{size:14}),` Joined`]}),t?(0,C.jsxs)(`div`,{className:`community-membership-popover`,children:[(0,C.jsx)(`strong`,{children:`Notifications`}),[`mentions`,`all`,`none`].map(t=>(0,C.jsxs)(`label`,{children:[(0,C.jsx)(`input`,{type:`radio`,name:`community-notifications`,checked:e.mode===t,disabled:e.busy,onChange:()=>void e.onMode(t)}),` `,t===`mentions`?`Mentions`:t===`all`?`All messages`:`Nothing`]},t)),(0,C.jsx)(`button`,{type:`button`,className:`danger`,disabled:e.busy,onClick:()=>{window.confirm(`Leave this community? You can join again later by accepting the current rules.`)&&e.onLeave().then(e=>{e&&n(!1)})},children:`Leave community`})]}):null]})}function B({name:e,imageUrl:t}){return t?(0,C.jsx)(`img`,{className:`community-icon`,src:t,alt:``}):(0,C.jsx)(`span`,{className:`community-icon fallback`,children:e.slice(0,2).toUpperCase()})}export{R as CommunityView};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{i as e}from"./rolldown-runtime-Dd_uD5pT.js";import{g as t,m as n}from"./index-
|
|
1
|
+
import{i as e}from"./rolldown-runtime-Dd_uD5pT.js";import{g as t,m as n}from"./index-DG0kf1wK.js";import{t as r}from"./requests-DmeUYik4.js";import"./icons-nr5d1kC-.js";import{T as i}from"./training-model-data-CilS0W2N.js";import{t as a}from"./x-CQ0pGF6Q.js";import{n as o,r as s,t as c}from"./AttachmentTypeIcon-AqiS2gzg.js";function l(e){return e?(e.match(/\r\n|\r|\n/g)?.length??0)+ +!/(?:\r\n|\r|\n)$/.test(e):0}var u=e(t(),1),d=n(),f=new Set([`csv`,`css`,`html`,`js`,`json`,`jsx`,`log`,`md`,`mdx`,`py`,`sql`,`svg`,`ts`,`tsx`,`txt`,`xml`,`yaml`,`yml`]),p=/^Pasted text(?: (\d+))?\.txt$/;function m(e,t){if(e.length<2e3)return null;let n=new Set;for(let e of t){let t=p.exec(e.name);t&&n.add(t[1]?Number(t[1]):1)}let r=1;for(;n.has(r);)r+=1;let i=r===1?`Pasted text.txt`:`Pasted text ${r}.txt`;return new File([e],i,{type:`text/plain`})}function h({attachment:e,onRemove:t}){let[n,r]=(0,u.useState)(!1),f=(0,u.useRef)(null),p=(0,u.useCallback)(()=>{r(!1),f.current?.focus()},[]),[m,h]=(0,u.useState)(null);(0,u.useEffect)(()=>{if(e.kind!==`text`)return;let t=!1;return e.file.text().then(e=>{t||h(l(e))},()=>void 0),()=>{t=!0}},[e.file,e.kind]);let g=e.kind!==`image`;return(0,d.jsxs)(`div`,{className:`composer-attachment-card ${e.kind}`,children:[e.kind===`image`&&e.previewUrl?(0,d.jsx)(`button`,{ref:f,type:`button`,className:`composer-attachment-thumb composer-attachment-preview`,"aria-label":`Preview ${e.name}`,title:`Preview ${e.name}`,onClick:()=>r(!0),children:(0,d.jsx)(`img`,{alt:``,decoding:`async`,src:e.previewUrl})}):(0,d.jsx)(`div`,{className:`composer-attachment-thumb`,"aria-hidden":`true`,children:(0,d.jsx)(c,{attachment:e,size:22})}),(0,d.jsx)(i,{open:n,src:e.previewUrl??null,title:e.name,onClose:p}),g?(0,d.jsxs)(`div`,{className:`composer-attachment-meta`,children:[(0,d.jsx)(`strong`,{children:e.name}),(0,d.jsx)(`span`,{children:e.kind===`text`&&m!==null?s(m):o(e)})]}):null,(0,d.jsx)(`button`,{type:`button`,className:`composer-attachment-remove`,"aria-label":`Remove ${e.name}`,onClick:t,children:(0,d.jsx)(a,{size:14})})]})}function g(){return globalThis.crypto?.randomUUID?.()??`attachment-${Date.now()}-${Math.random().toString(36).slice(2)}`}function _(e){if(e.type.startsWith(`image/`))return`image`;if(e.type.startsWith(`text/`))return`text`;let t=e.name.split(`.`).pop()?.toLowerCase()??``;return f.has(t)?`text`:`file`}async function v(e){let[t,n]=await Promise.all([b(e.file),e.kind===`text`?x(e.file):Promise.resolve(void 0)]);return{id:e.id,name:e.name,mediaType:e.mediaType,sizeBytes:e.sizeBytes,kind:e.kind,...n===void 0?{}:{lineCount:l(n)},...e.relativePath?{relativePath:e.relativePath}:{},contentsBase64:t,...n?{text:S(n)}:{}}}function y(e){if(e<1024)return`${e} B`;let t=[`KB`,`MB`,`GB`],n=e/1024;for(let e of t){if(n<1024)return`${n.toFixed(n>=10?0:1)} ${e}`;n/=1024}return`${n.toFixed(0)} TB`}function b(e){return new Promise((t,n)=>{let r=new FileReader;r.onload=()=>{let[,e=``]=(typeof r.result==`string`?r.result:``).split(`,`,2);t(e)},r.onerror=()=>n(r.error??Error(`Failed to read file`)),r.readAsDataURL(e)})}function x(e){return new Promise((t,n)=>{let r=new FileReader;r.onload=()=>t(typeof r.result==`string`?r.result:``),r.onerror=()=>n(r.error??Error(`Failed to read file`)),r.readAsText(e)})}function S(e){return e.length<=r.maxTextChars?e:`${e.slice(0,Math.max(0,r.maxTextChars-28))}
|
|
2
2
|
[attachment text truncated]`}export{y as a,m as i,_ as n,v as o,g as r,h as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{i as e,n as t}from"./rolldown-runtime-Dd_uD5pT.js";import{g as n,m as r}from"./index-CDtTBysF.js";import{n as i}from"./create-pipeline-DsZzNkt9.js";import"./icons-CYvTltSH.js";import{I as a}from"./training-model-data-vvvphDlO.js";import{t as o}from"./loader-circle-AjP2mDJA.js";import{t as s}from"./play-BrvX67t1.js";import{t as c}from"./refresh-cw-Cx_7Zlbl.js";import{t as l}from"./x-EG07vYCF.js";import{gn as u,in as d,mn as f,un as p}from"./App-CV1p0_Zy.js";var m=t({ComposerCreateImproveStrip:()=>_}),h=e(n(),1),g=r();function _({runtime:e}){let[t,n]=(0,h.useState)(!1),[r,i]=(0,h.useState)(``),[m,_]=(0,h.useState)(null),D=e.run,O=D.plan,k=v(D),A={run:D},j=S(D.state),M=w(D),N=M?.git?.pullRequest??D.releaseOutcome.pullRequest;(0,h.useEffect)(()=>{n(!1),i(``),_(null)},[D.id,D.revision,D.state,O?.id,k?.id]);async function P(e,t){if(t&&!m){_(e);try{await t()}finally{_(null)}}}return(0,g.jsxs)(`section`,{"data-notification-run":D.id,className:`composer-create-strip ${j}`,"aria-label":`Create or improve status`,children:[(0,g.jsxs)(`div`,{className:`composer-create-strip-heading`,children:[j===`danger`?(0,g.jsx)(f,{size:15}):D.state===`awaiting_questions`?(0,g.jsx)(d,{size:15}):C(D.state)?(0,g.jsx)(o,{className:`composer-create-spin`,size:15}):(0,g.jsx)(p,{size:15}),(0,g.jsx)(`span`,{children:b(D)}),(0,g.jsx)(`small`,{children:D.target.kind})]}),D.state===`awaiting_questions`&&k?(0,g.jsxs)(`div`,{className:`composer-create-question`,children:[(0,g.jsx)(`p`,{children:k.prompt}),(0,g.jsx)(`div`,{className:`composer-create-options`,children:k.options.map(t=>(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>void P(`answer:${t.id}`,()=>e.onAnswerQuestion?e.onAnswerQuestion(A,k.id,t.value):Promise.resolve()),children:[(0,g.jsx)(`span`,{children:m===`answer:${t.id}`?`Saving`:t.label}),t.description?(0,g.jsx)(`small`,{children:t.description}):null]},t.id))})]}):D.state===`awaiting_plan_approval`&&O?(0,g.jsxs)(`div`,{className:`composer-create-plan-summary`,children:[(0,g.jsx)(`p`,{children:O.summary}),(0,g.jsx)(y,{run:D}),t?(0,g.jsxs)(`div`,{className:`composer-create-revision`,children:[(0,g.jsx)(`textarea`,{rows:2,value:r,placeholder:`Describe the plan revision`,onChange:e=>i(e.currentTarget.value)}),(0,g.jsxs)(`div`,{children:[(0,g.jsxs)(`button`,{type:`button`,disabled:!r.trim()||!!m,onClick:()=>void P(`revise`,()=>e.onRevise?e.onRevise(A,r):Promise.resolve()),children:[(0,g.jsx)(p,{size:13}),(0,g.jsx)(`span`,{children:m===`revise`?`Saving`:`Save revision`})]}),(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>n(!1),children:[(0,g.jsx)(l,{size:13}),(0,g.jsx)(`span`,{children:`Close`})]})]})]}):(0,g.jsxs)(`div`,{className:`composer-create-actions`,children:[(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>void P(`approve`,()=>e.onApprove?e.onApprove(A):Promise.resolve()),children:[(0,g.jsx)(u,{size:13}),(0,g.jsx)(`span`,{children:m===`approve`?`Confirming`:`Confirm plan`})]}),(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>n(!0),children:[(0,g.jsx)(p,{size:13}),(0,g.jsx)(`span`,{children:`Edit plan`})]}),(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>void P(`cancel`,()=>e.onCancel?e.onCancel(A):Promise.resolve()),children:[(0,g.jsx)(l,{size:13}),(0,g.jsx)(`span`,{children:m===`cancel`?`Cancelling`:`Cancel`})]})]})]}):D.state===`paused`?(0,g.jsxs)(`div`,{className:`composer-create-status-body`,children:[(0,g.jsx)(`p`,{children:`This work is paused. Resume it when you are ready to continue.`}),(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>void P(`resume`,()=>e.onResume?e.onResume(A):Promise.resolve()),children:[(0,g.jsx)(s,{size:13}),(0,g.jsx)(`span`,{children:m===`resume`?`Resuming`:`Resume`})]})]}):D.state===`awaiting_promotion`&&M?(0,g.jsxs)(`div`,{className:`composer-create-status-body`,children:[(0,g.jsx)(`p`,{children:E(D,M.id)}),(0,g.jsxs)(`div`,{className:`composer-create-actions`,children:[(0,g.jsxs)(`button`,{type:`button`,disabled:!!m||!T(D,M.id),onClick:()=>void P(`apply-candidate`,()=>e.onApplyCandidate?e.onApplyCandidate(A,M.id):Promise.resolve()),children:[(0,g.jsx)(u,{size:13}),(0,g.jsx)(`span`,{children:m===`apply-candidate`?`Applying`:`Apply update`})]}),(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>void P(`reject-candidate`,()=>e.onRejectCandidate?e.onRejectCandidate(A,M.id):Promise.resolve()),children:[(0,g.jsx)(l,{size:13}),(0,g.jsx)(`span`,{children:m===`reject-candidate`?`Keeping current version`:`Keep current version`})]})]})]}):D.state===`pull_request_open`&&M&&N?(0,g.jsxs)(`div`,{className:`composer-create-status-body`,children:[(0,g.jsx)(`p`,{children:D.target.kind===`agent`?`An Agent update review is open. Finish or close it, then refresh its status.`:`An external review is open. Merge or close it, then refresh its status.`}),(0,g.jsxs)(`div`,{className:`composer-create-actions`,children:[(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>void P(`reconcile-pr`,()=>e.onReconcilePullRequest?e.onReconcilePullRequest(A,M.id):Promise.resolve()),children:[(0,g.jsx)(c,{size:13}),(0,g.jsx)(`span`,{children:m===`reconcile-pr`?`Checking`:`Refresh review`})]}),(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>void P(`reject-candidate`,()=>e.onRejectCandidate?e.onRejectCandidate(A,M.id):Promise.resolve()),children:[(0,g.jsx)(l,{size:13}),(0,g.jsx)(`span`,{children:m===`reject-candidate`?`Closing`:`Close review`})]})]})]}):D.state===`blocked`||D.state===`failed`||D.state===`cancelled`?(0,g.jsxs)(`div`,{className:`composer-create-status-body`,children:[(0,g.jsx)(`p`,{children:D.blockedReason??`This work stopped before it was ready.`}),D.state===`blocked`&&M?.git?.worktreePath&&[`draft`,`checking`].includes(M.status)?(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>void P(`resume`,()=>e.onResume?e.onResume(A):Promise.resolve()),children:[(0,g.jsx)(s,{size:13}),(0,g.jsx)(`span`,{children:m===`resume`?`Continuing`:`Continue update`})]}):D.state===`blocked`&&M?.git?.pullRequest?.state===`merged`?(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>void P(`reconcile-pr`,()=>e.onReconcilePullRequest?e.onReconcilePullRequest(A,M.id):Promise.resolve()),children:[(0,g.jsx)(c,{size:13}),(0,g.jsx)(`span`,{children:m===`reconcile-pr`?`Checking`:`Re-run verification`})]}):null]}):D.state===`released`||D.state===`rejected`||D.state===`ready_local`||D.state===`ready`||D.state===`published_hosted`?(0,g.jsxs)(`div`,{className:`composer-create-status-body composer-create-status-body-reveals`,children:[(0,g.jsx)(`p`,{children:D.state===`released`?`The Agent update is saved and its Evals passed.`:D.state===`rejected`?`The Agent update was not applied.`:D.state===`published_hosted`?`Published to the hosted Profile.`:`The Agent and its actions are ready to use.`}),(0,g.jsx)(`div`,{className:`composer-create-hover-details`,children:(0,g.jsx)(y,{run:D})})]}):(0,g.jsxs)(`div`,{className:`composer-create-status-body`,children:[(0,g.jsx)(`p`,{children:x(D)}),(0,g.jsx)(y,{run:D}),D.executionPolicy.pauseAllowed&&e.onPause?(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>void P(`pause`,()=>e.onPause?.(A)??Promise.resolve()),children:[(0,g.jsx)(a,{size:13}),(0,g.jsx)(`span`,{children:m===`pause`?`Pausing`:`Pause`})]}):null]})]})}function v(e){return e.questions.find(e=>e.status===`pending`&&e.required)??e.questions.find(e=>e.status===`pending`)??null}function y({run:e}){let t=e.plan,n=e.target.kind===`agent`,r=n?null:e.sourceRefs[0]??t?.sourcePlan[0]?.path??null,a=e.checkRefs.length||t?.checks.length||0,o=n?0:t?.requirements.length??0,s=n?[]:[...e.sourceRefs,...e.checkRefs].slice(0,4),c=i(t?.metadata);return!r&&a===0&&o===0&&s.length===0&&!c?null:(0,g.jsxs)(g.Fragment,{children:[(0,g.jsxs)(`div`,{className:`composer-create-facts`,children:[c?(0,g.jsx)(`span`,{title:c.detail,children:c.label}):null,r?(0,g.jsx)(`span`,{title:r,children:r}):null,a?(0,g.jsx)(`span`,{children:n?`${a} Evals`:e.checkRefs.length?`${e.checkRefs.length} check refs`:`${a} checks`}):null,o?(0,g.jsxs)(`span`,{children:[o,` setup rows`]}):null]}),s.length?(0,g.jsx)(`ul`,{className:`composer-create-refs`,"aria-label":`Source and check refs`,children:s.map(e=>(0,g.jsx)(`li`,{children:(0,g.jsx)(`code`,{title:e,children:e})},e))}):null]})}function b(e){let t=e.target.kind===`agent`;return e.state===`awaiting_questions`?`Question`:e.state===`awaiting_plan_approval`?`Plan`:e.state===`applying_source`?t?`Saving Agent`:`Applying source`:e.state===`running_checks`?`Running Evals`:e.state===`evaluating`?t?`Checking Agent`:`Evaluating`:e.state===`awaiting_promotion`?t?`Update ready`:`Candidate ready`:e.state===`opening_pull_request`?`Opening review`:e.state===`pull_request_open`?`Review open`:e.state===`reconciling_release`?t?`Applying update`:`Merging change`:e.state===`released`?t?`Agent updated`:`Released`:e.state===`rejected`?t?`Current Agent kept`:`Rejected`:e.state===`paused`?`Paused`:e.state===`ready`||e.state===`ready_local`?`Ready`:e.state===`published_hosted`?`Published`:e.state===`cancelled`?`Cancelled`:e.state===`blocked`?`Blocked`:e.state===`failed`?`Failed`:e.operation===`improve`?`Improve`:`Create`}function x(e){let t=e.state,n=e.target.kind===`agent`;return t===`applying_source`?n?`Saving the approved Agent plan.`:`Applying the approved source changes.`:t===`running_checks`?n?`Running Evals against the Agent.`:`Running checks against the candidate.`:t===`evaluating`?n?`Checking the Agent's behavior.`:`Evaluating the candidate against its Evals.`:t===`opening_pull_request`?n?`Preparing the Agent update review.`:`Opening the candidate review.`:t===`reconciling_release`?`Applying the change and verifying the active Profile.`:t===`pushing_hosted`?`Pushing the Profile source.`:t===`running_hosted_checks`?n?`Running hosted Evals.`:`Running hosted checks.`:`Preparing the work.`}function S(e){return[`released`,`ready`,`ready_local`,`published_hosted`].includes(e)?`success`:[`rejected`,`blocked`,`failed`,`cancelled`].includes(e)?`danger`:[`awaiting_questions`,`awaiting_plan_approval`,`awaiting_promotion`,`pull_request_open`,`paused`].includes(e)?`warning`:`info`}function C(e){return[`planning`,`applying_source`,`running_checks`,`evaluating`,`opening_pull_request`,`reconciling_release`,`pushing_hosted`,`running_hosted_checks`].includes(e)}function w(e){return[...e.candidates].reverse().find(e=>e.target.kind===`agent`)??null}function T(e,t){let n=e.evaluationReceipts.filter(e=>e.candidateId===t&&e.subject===`candidate`);return n.length>0&&n.every(e=>e.status===`passed`&&e.publishGate!==`failed`)}function E(e,t){let n=e.evaluationReceipts.find(e=>e.candidateId===t&&e.subject===`active`),r=e.evaluationReceipts.find(e=>e.candidateId===t&&e.subject===`candidate`),i=e=>e?.summaryCounts?`${e.summaryCounts.passed}/${e.summaryCounts.total}`:e?.status??`not run`;return e.target.kind===`agent`?`Current Agent: ${i(n)} Evals passed. Updated Agent: ${i(r)} Evals passed.`:`Base Evals: ${i(n)} passed. Candidate Evals: ${i(r)} passed.`}export{m as n,_ as t};
|
|
1
|
+
import{i as e,n as t}from"./rolldown-runtime-Dd_uD5pT.js";import{g as n,m as r}from"./index-DG0kf1wK.js";import{n as i}from"./create-pipeline-DsZzNkt9.js";import"./icons-nr5d1kC-.js";import{I as a}from"./training-model-data-CilS0W2N.js";import{t as o}from"./loader-circle-C1-u7BUs.js";import{t as s}from"./play-DF5h_-8T.js";import{t as c}from"./refresh-cw-avBifyns.js";import{t as l}from"./x-CQ0pGF6Q.js";import{gn as u,in as d,mn as f,un as p}from"./App-CqqK4NLa.js";var m=t({ComposerCreateImproveStrip:()=>_}),h=e(n(),1),g=r();function _({runtime:e}){let[t,n]=(0,h.useState)(!1),[r,i]=(0,h.useState)(``),[m,_]=(0,h.useState)(null),D=e.run,O=D.plan,k=v(D),A={run:D},j=S(D.state),M=w(D),N=M?.git?.pullRequest??D.releaseOutcome.pullRequest;(0,h.useEffect)(()=>{n(!1),i(``),_(null)},[D.id,D.revision,D.state,O?.id,k?.id]);async function P(e,t){if(t&&!m){_(e);try{await t()}finally{_(null)}}}return(0,g.jsxs)(`section`,{"data-notification-run":D.id,className:`composer-create-strip ${j}`,"aria-label":`Create or improve status`,children:[(0,g.jsxs)(`div`,{className:`composer-create-strip-heading`,children:[j===`danger`?(0,g.jsx)(f,{size:15}):D.state===`awaiting_questions`?(0,g.jsx)(d,{size:15}):C(D.state)?(0,g.jsx)(o,{className:`composer-create-spin`,size:15}):(0,g.jsx)(p,{size:15}),(0,g.jsx)(`span`,{children:b(D)}),(0,g.jsx)(`small`,{children:D.target.kind})]}),D.state===`awaiting_questions`&&k?(0,g.jsxs)(`div`,{className:`composer-create-question`,children:[(0,g.jsx)(`p`,{children:k.prompt}),(0,g.jsx)(`div`,{className:`composer-create-options`,children:k.options.map(t=>(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>void P(`answer:${t.id}`,()=>e.onAnswerQuestion?e.onAnswerQuestion(A,k.id,t.value):Promise.resolve()),children:[(0,g.jsx)(`span`,{children:m===`answer:${t.id}`?`Saving`:t.label}),t.description?(0,g.jsx)(`small`,{children:t.description}):null]},t.id))})]}):D.state===`awaiting_plan_approval`&&O?(0,g.jsxs)(`div`,{className:`composer-create-plan-summary`,children:[(0,g.jsx)(`p`,{children:O.summary}),(0,g.jsx)(y,{run:D}),t?(0,g.jsxs)(`div`,{className:`composer-create-revision`,children:[(0,g.jsx)(`textarea`,{rows:2,value:r,placeholder:`Describe the plan revision`,onChange:e=>i(e.currentTarget.value)}),(0,g.jsxs)(`div`,{children:[(0,g.jsxs)(`button`,{type:`button`,disabled:!r.trim()||!!m,onClick:()=>void P(`revise`,()=>e.onRevise?e.onRevise(A,r):Promise.resolve()),children:[(0,g.jsx)(p,{size:13}),(0,g.jsx)(`span`,{children:m===`revise`?`Saving`:`Save revision`})]}),(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>n(!1),children:[(0,g.jsx)(l,{size:13}),(0,g.jsx)(`span`,{children:`Close`})]})]})]}):(0,g.jsxs)(`div`,{className:`composer-create-actions`,children:[(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>void P(`approve`,()=>e.onApprove?e.onApprove(A):Promise.resolve()),children:[(0,g.jsx)(u,{size:13}),(0,g.jsx)(`span`,{children:m===`approve`?`Confirming`:`Confirm plan`})]}),(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>n(!0),children:[(0,g.jsx)(p,{size:13}),(0,g.jsx)(`span`,{children:`Edit plan`})]}),(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>void P(`cancel`,()=>e.onCancel?e.onCancel(A):Promise.resolve()),children:[(0,g.jsx)(l,{size:13}),(0,g.jsx)(`span`,{children:m===`cancel`?`Cancelling`:`Cancel`})]})]})]}):D.state===`paused`?(0,g.jsxs)(`div`,{className:`composer-create-status-body`,children:[(0,g.jsx)(`p`,{children:`This work is paused. Resume it when you are ready to continue.`}),(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>void P(`resume`,()=>e.onResume?e.onResume(A):Promise.resolve()),children:[(0,g.jsx)(s,{size:13}),(0,g.jsx)(`span`,{children:m===`resume`?`Resuming`:`Resume`})]})]}):D.state===`awaiting_promotion`&&M?(0,g.jsxs)(`div`,{className:`composer-create-status-body`,children:[(0,g.jsx)(`p`,{children:E(D,M.id)}),(0,g.jsxs)(`div`,{className:`composer-create-actions`,children:[(0,g.jsxs)(`button`,{type:`button`,disabled:!!m||!T(D,M.id),onClick:()=>void P(`apply-candidate`,()=>e.onApplyCandidate?e.onApplyCandidate(A,M.id):Promise.resolve()),children:[(0,g.jsx)(u,{size:13}),(0,g.jsx)(`span`,{children:m===`apply-candidate`?`Applying`:`Apply update`})]}),(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>void P(`reject-candidate`,()=>e.onRejectCandidate?e.onRejectCandidate(A,M.id):Promise.resolve()),children:[(0,g.jsx)(l,{size:13}),(0,g.jsx)(`span`,{children:m===`reject-candidate`?`Keeping current version`:`Keep current version`})]})]})]}):D.state===`pull_request_open`&&M&&N?(0,g.jsxs)(`div`,{className:`composer-create-status-body`,children:[(0,g.jsx)(`p`,{children:D.target.kind===`agent`?`An Agent update review is open. Finish or close it, then refresh its status.`:`An external review is open. Merge or close it, then refresh its status.`}),(0,g.jsxs)(`div`,{className:`composer-create-actions`,children:[(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>void P(`reconcile-pr`,()=>e.onReconcilePullRequest?e.onReconcilePullRequest(A,M.id):Promise.resolve()),children:[(0,g.jsx)(c,{size:13}),(0,g.jsx)(`span`,{children:m===`reconcile-pr`?`Checking`:`Refresh review`})]}),(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>void P(`reject-candidate`,()=>e.onRejectCandidate?e.onRejectCandidate(A,M.id):Promise.resolve()),children:[(0,g.jsx)(l,{size:13}),(0,g.jsx)(`span`,{children:m===`reject-candidate`?`Closing`:`Close review`})]})]})]}):D.state===`blocked`||D.state===`failed`||D.state===`cancelled`?(0,g.jsxs)(`div`,{className:`composer-create-status-body`,children:[(0,g.jsx)(`p`,{children:D.blockedReason??`This work stopped before it was ready.`}),D.state===`blocked`&&M?.git?.worktreePath&&[`draft`,`checking`].includes(M.status)?(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>void P(`resume`,()=>e.onResume?e.onResume(A):Promise.resolve()),children:[(0,g.jsx)(s,{size:13}),(0,g.jsx)(`span`,{children:m===`resume`?`Continuing`:`Continue update`})]}):D.state===`blocked`&&M?.git?.pullRequest?.state===`merged`?(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>void P(`reconcile-pr`,()=>e.onReconcilePullRequest?e.onReconcilePullRequest(A,M.id):Promise.resolve()),children:[(0,g.jsx)(c,{size:13}),(0,g.jsx)(`span`,{children:m===`reconcile-pr`?`Checking`:`Re-run verification`})]}):null]}):D.state===`released`||D.state===`rejected`||D.state===`ready_local`||D.state===`ready`||D.state===`published_hosted`?(0,g.jsxs)(`div`,{className:`composer-create-status-body composer-create-status-body-reveals`,children:[(0,g.jsx)(`p`,{children:D.state===`released`?`The Agent update is saved and its Evals passed.`:D.state===`rejected`?`The Agent update was not applied.`:D.state===`published_hosted`?`Published to the hosted Profile.`:`The Agent and its actions are ready to use.`}),(0,g.jsx)(`div`,{className:`composer-create-hover-details`,children:(0,g.jsx)(y,{run:D})})]}):(0,g.jsxs)(`div`,{className:`composer-create-status-body`,children:[(0,g.jsx)(`p`,{children:x(D)}),(0,g.jsx)(y,{run:D}),D.executionPolicy.pauseAllowed&&e.onPause?(0,g.jsxs)(`button`,{type:`button`,disabled:!!m,onClick:()=>void P(`pause`,()=>e.onPause?.(A)??Promise.resolve()),children:[(0,g.jsx)(a,{size:13}),(0,g.jsx)(`span`,{children:m===`pause`?`Pausing`:`Pause`})]}):null]})]})}function v(e){return e.questions.find(e=>e.status===`pending`&&e.required)??e.questions.find(e=>e.status===`pending`)??null}function y({run:e}){let t=e.plan,n=e.target.kind===`agent`,r=n?null:e.sourceRefs[0]??t?.sourcePlan[0]?.path??null,a=e.checkRefs.length||t?.checks.length||0,o=n?0:t?.requirements.length??0,s=n?[]:[...e.sourceRefs,...e.checkRefs].slice(0,4),c=i(t?.metadata);return!r&&a===0&&o===0&&s.length===0&&!c?null:(0,g.jsxs)(g.Fragment,{children:[(0,g.jsxs)(`div`,{className:`composer-create-facts`,children:[c?(0,g.jsx)(`span`,{title:c.detail,children:c.label}):null,r?(0,g.jsx)(`span`,{title:r,children:r}):null,a?(0,g.jsx)(`span`,{children:n?`${a} Evals`:e.checkRefs.length?`${e.checkRefs.length} check refs`:`${a} checks`}):null,o?(0,g.jsxs)(`span`,{children:[o,` setup rows`]}):null]}),s.length?(0,g.jsx)(`ul`,{className:`composer-create-refs`,"aria-label":`Source and check refs`,children:s.map(e=>(0,g.jsx)(`li`,{children:(0,g.jsx)(`code`,{title:e,children:e})},e))}):null]})}function b(e){let t=e.target.kind===`agent`;return e.state===`awaiting_questions`?`Question`:e.state===`awaiting_plan_approval`?`Plan`:e.state===`applying_source`?t?`Saving Agent`:`Applying source`:e.state===`running_checks`?`Running Evals`:e.state===`evaluating`?t?`Checking Agent`:`Evaluating`:e.state===`awaiting_promotion`?t?`Update ready`:`Candidate ready`:e.state===`opening_pull_request`?`Opening review`:e.state===`pull_request_open`?`Review open`:e.state===`reconciling_release`?t?`Applying update`:`Merging change`:e.state===`released`?t?`Agent updated`:`Released`:e.state===`rejected`?t?`Current Agent kept`:`Rejected`:e.state===`paused`?`Paused`:e.state===`ready`||e.state===`ready_local`?`Ready`:e.state===`published_hosted`?`Published`:e.state===`cancelled`?`Cancelled`:e.state===`blocked`?`Blocked`:e.state===`failed`?`Failed`:e.operation===`improve`?`Improve`:`Create`}function x(e){let t=e.state,n=e.target.kind===`agent`;return t===`applying_source`?n?`Saving the approved Agent plan.`:`Applying the approved source changes.`:t===`running_checks`?n?`Running Evals against the Agent.`:`Running checks against the candidate.`:t===`evaluating`?n?`Checking the Agent's behavior.`:`Evaluating the candidate against its Evals.`:t===`opening_pull_request`?n?`Preparing the Agent update review.`:`Opening the candidate review.`:t===`reconciling_release`?`Applying the change and verifying the active Profile.`:t===`pushing_hosted`?`Pushing the Profile source.`:t===`running_hosted_checks`?n?`Running hosted Evals.`:`Running hosted checks.`:`Preparing the work.`}function S(e){return[`released`,`ready`,`ready_local`,`published_hosted`].includes(e)?`success`:[`rejected`,`blocked`,`failed`,`cancelled`].includes(e)?`danger`:[`awaiting_questions`,`awaiting_plan_approval`,`awaiting_promotion`,`pull_request_open`,`paused`].includes(e)?`warning`:`info`}function C(e){return[`planning`,`applying_source`,`running_checks`,`evaluating`,`opening_pull_request`,`reconciling_release`,`pushing_hosted`,`running_hosted_checks`].includes(e)}function w(e){return[...e.candidates].reverse().find(e=>e.target.kind===`agent`)??null}function T(e,t){let n=e.evaluationReceipts.filter(e=>e.candidateId===t&&e.subject===`candidate`);return n.length>0&&n.every(e=>e.status===`passed`&&e.publishGate!==`failed`)}function E(e,t){let n=e.evaluationReceipts.find(e=>e.candidateId===t&&e.subject===`active`),r=e.evaluationReceipts.find(e=>e.candidateId===t&&e.subject===`candidate`),i=e=>e?.summaryCounts?`${e.summaryCounts.passed}/${e.summaryCounts.total}`:e?.status??`not run`;return e.target.kind===`agent`?`Current Agent: ${i(n)} Evals passed. Updated Agent: ${i(r)} Evals passed.`:`Base Evals: ${i(n)} passed. Candidate Evals: ${i(r)} passed.`}export{m as n,_ as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{i as e}from"./rolldown-runtime-Dd_uD5pT.js";import{g as t,m as n}from"./index-
|
|
1
|
+
import{i as e}from"./rolldown-runtime-Dd_uD5pT.js";import{g as t,m as n}from"./index-DG0kf1wK.js";import{n as r}from"./api-client-DJRVOFzS.js";import{t as i}from"./NativeSetupTerminal-BXvrxj-m.js";import{Gt as a,Nt as o}from"./App-CqqK4NLa.js";import{n as s,r as c,t as l}from"./useAgentInventory-8MWE3pbH.js";var u=e(t(),1),d=n(),f=[`Sunday`,`Monday`,`Tuesday`,`Wednesday`,`Thursday`,`Friday`,`Saturday`];function p({schedule:e,name:t,disabled:n,disconnected:r,onSave:i}){let[a,o]=(0,u.useState)(null),s=a??{enabled:!!e,frequency:e?.frequency??`daily`,time:e?.frequency===`daily`||e?.frequency===`weekly`?e.time:`00:00`,day:e?.frequency===`weekly`?e.day:1,expression:e?.frequency===`cron`?e.expression:`0 * * * *`},{enabled:c,frequency:l,time:p,day:m,expression:h}=s,g=c?l===`cron`?{frequency:l,expression:h.trim()}:l===`hourly`?{frequency:l}:l===`weekly`?{frequency:l,time:p,day:m}:{frequency:l,time:p}:null,_=JSON.stringify(g)!==JSON.stringify(e),v=n||!c||r,y=l===`daily`||l===`weekly`;return(0,d.jsxs)(`form`,{className:`conversation-import-schedule`,onSubmit:e=>{e.preventDefault(),i(g).then(()=>o(null)).catch(()=>{})},children:[(0,d.jsxs)(`label`,{children:[(0,d.jsx)(`input`,{type:`checkbox`,checked:c,disabled:n||r&&!c,onChange:e=>o({...s,enabled:e.target.checked})}),`Continual imports`]}),(0,d.jsxs)(`label`,{children:[`Frequency`,(0,d.jsxs)(`select`,{"aria-label":`${t} import frequency`,value:l,disabled:v,onChange:e=>o({...s,frequency:e.target.value}),children:[(0,d.jsx)(`option`,{value:`hourly`,children:`Hourly`}),(0,d.jsx)(`option`,{value:`daily`,children:`Daily`}),(0,d.jsx)(`option`,{value:`weekly`,children:`Weekly`}),(0,d.jsx)(`option`,{value:`cron`,children:`Custom cron`})]})]}),l===`weekly`?(0,d.jsxs)(`label`,{children:[`Day`,(0,d.jsx)(`select`,{"aria-label":`${t} import day`,value:m,disabled:v,onChange:e=>o({...s,day:Number(e.target.value)}),children:f.map((e,t)=>(0,d.jsx)(`option`,{value:t,children:e},e))})]}):null,y?(0,d.jsxs)(`label`,{children:[`Sync time`,(0,d.jsx)(`input`,{"aria-label":`${t} sync time`,type:`time`,required:c,value:p,disabled:v,onChange:e=>o({...s,time:e.target.value})})]}):null,l===`cron`?(0,d.jsxs)(`label`,{children:[`Cron expression`,(0,d.jsx)(`input`,{"aria-label":`${t} cron expression`,type:`text`,required:c,maxLength:512,value:h,placeholder:`0 * * * *`,disabled:v,onChange:e=>o({...s,expression:e.target.value})})]}):null,(0,d.jsx)(`button`,{className:`settings-secondary`,type:`submit`,disabled:n||!_||c&&(y?!p:l===`cron`&&!h.trim()),children:c?`Save schedule`:`Disable continual imports`}),(0,d.jsxs)(`small`,{children:[l===`cron`?`Five fields: minute, hour, day of month, month, day of week. For example, 0 * * * * runs hourly. Choose a single minute; faster schedules are not supported. `:l===`hourly`?`Runs at the start of each hour. `:`Midnight leaves time before a 2 a.m. model run. `,`A running import is never overlapped. Changing this setting does not start an import.`]})]})}var m=(e,t)=>e?new Date(e).toLocaleString(void 0,{timeZone:t}):`Not yet`;function h({connection:e}){let{inventory:t,loading:n,error:s,refresh:c}=l(e),[f,p]=(0,u.useState)(!1),[m,h]=(0,u.useState)(null),[_,v]=(0,u.useState)(null);async function y(t,n,i){if(e&&!f){p(!0),h(null);try{let a=await r(e,`/v1/native-history/collector`,{method:`POST`,body:JSON.stringify({command:t,connectionId:n,...i===void 0?{}:{schedule:i}})});a.command&&v(a.command),await c()}catch(e){throw h(e instanceof Error?e.message:`Unable to update conversation imports.`),e}finally{p(!1)}}}let b=(e,t)=>{y(e,t).catch(()=>{})};return(0,d.jsxs)(`section`,{className:`account-settings conversation-imports`,children:[(0,d.jsxs)(`div`,{className:`conversation-imports-heading`,children:[(0,d.jsxs)(`div`,{children:[(0,d.jsx)(`h1`,{children:`Conversation imports`}),(0,d.jsx)(`p`,{children:`Import saved conversations once, or choose a separate recurring schedule for each source.`})]}),(0,d.jsx)(`button`,{className:`settings-secondary`,type:`button`,disabled:n,onClick:()=>void c(),children:`Refresh`})]}),(0,d.jsxs)(`p`,{children:[`Continual imports use this computer’s local time`,t?` (${t.collector.timezone})`:``,`. If it is off or asleep, that run is skipped. The next scheduled run picks up changes from missed days.`]}),(0,d.jsx)(`p`,{children:`Imports do not enable continual learning or change model training schedules.`}),m??s?(0,d.jsx)(a,{error:m??s}):null,e?null:(0,d.jsx)(`p`,{children:`Connect to a desktop runtime to manage imports.`}),n&&!t?(0,d.jsx)(`p`,{role:`status`,children:`Loading conversation imports…`}):null,t?(0,d.jsxs)(d.Fragment,{children:[(0,d.jsxs)(`div`,{className:`conversation-imports-toolbar`,children:[(0,d.jsx)(`strong`,{role:`status`,children:t.collector.running?`Import in progress`:`No import running`}),t.collector.running?(0,d.jsx)(`button`,{className:`settings-secondary`,type:`button`,disabled:f,onClick:()=>b(`stop`),children:`Cancel current run`}):null]}),t.collector.connections.length?t.collector.connections.map(e=>(0,d.jsx)(g,{item:e,status:t.collector,disabled:f||_!==null,onAction:b,onSchedule:t=>y(`schedule`,e.id,t)},e.id)):(0,d.jsxs)(`div`,{className:`conversation-imports-empty`,children:[(0,d.jsx)(`p`,{children:`No conversation sources connected. Choose a source in Connections and import its recent history.`}),(0,d.jsx)(`button`,{className:`settings-secondary`,type:`button`,onClick:()=>o({kind:`view`,view:`apps`}),children:`Open Connections`})]}),(0,d.jsxs)(`details`,{children:[(0,d.jsx)(`summary`,{children:`CLI and local state`}),(0,d.jsx)(`p`,{children:t.directory}),(0,d.jsx)(`code`,{children:t.statusCommand})]})]}):null,_&&e?(0,d.jsx)(i,{connection:e,command:_,onComplete:()=>void c(),onClose:()=>{v(null),c()}}):null]})}function g({item:e,status:t,disabled:n,onAction:r,onSchedule:i}){let a=s.find(t=>t.id===e.source),l=e.run,u=t.running&&l?.state===`running`;return(0,d.jsxs)(`article`,{className:`conversation-import-card`,children:[(0,d.jsxs)(`div`,{className:`conversation-import-card-heading`,children:[(0,d.jsx)(`h3`,{children:a?.name??e.source}),(0,d.jsx)(`span`,{children:c(e,t)})]}),(0,d.jsxs)(`dl`,{className:`conversation-import-details`,children:[(0,d.jsxs)(`div`,{children:[(0,d.jsx)(`dt`,{children:`Destination`}),(0,d.jsx)(`dd`,{children:e.accountBaseUrl??`Hosted destination`})]}),(0,d.jsxs)(`div`,{children:[(0,d.jsx)(`dt`,{children:`Project`}),(0,d.jsx)(`dd`,{children:e.projectId})]}),(0,d.jsxs)(`div`,{children:[(0,d.jsx)(`dt`,{children:`Source`}),(0,d.jsx)(`dd`,{children:e.sourceRoot})]}),(0,d.jsxs)(`div`,{children:[(0,d.jsx)(`dt`,{children:`Initial history`}),(0,d.jsx)(`dd`,{children:e.since?`Since ${m(e.since,t.timezone)}`:`All history`})]}),(0,d.jsxs)(`div`,{children:[(0,d.jsx)(`dt`,{children:`Upload selection`}),(0,d.jsx)(`dd`,{children:e.selectedConversations===null?`All history`:`${e.selectedConversations} approved conversations`})]}),(0,d.jsxs)(`div`,{children:[(0,d.jsx)(`dt`,{children:`Last successful sync`}),(0,d.jsx)(`dd`,{children:m(e.lastSuccessfulSyncAt,t.timezone)})]}),(0,d.jsxs)(`div`,{children:[(0,d.jsx)(`dt`,{children:`Next sync`}),(0,d.jsx)(`dd`,{children:e.nextRunAt?m(e.nextRunAt,t.timezone):e.schedule?`Source paused or disconnected`:`Manual only`})]})]}),u&&l?(0,d.jsxs)(`div`,{role:`status`,className:`conversation-import-progress`,children:[(0,d.jsxs)(`span`,{children:[l.phase===`uploading`?`Uploading conversations`:l.phase===`discovering`?`Finding conversations`:`Reading conversations`,` · `,l.processed,` of `,l.discovered,` checked`]}),l.discovered>0?(0,d.jsx)(`progress`,{value:l.processed,max:l.discovered,"aria-label":`${a?.name??e.source} import progress`}):(0,d.jsx)(`progress`,{"aria-label":`Finding conversations`}),(0,d.jsxs)(`small`,{children:[l.uploaded,` turns uploaded · `,e.queued,` updates queued`]})]}):(0,d.jsxs)(`p`,{children:[e.admitted,` turns imported · `,e.queued,` updates queued`,l?.state===`cancelled`?` · Last run cancelled`:``]}),e.error||l?.state===`failed`?(0,d.jsx)(`p`,{role:`alert`,children:e.error??l?.error}):null,(0,d.jsx)(p,{schedule:e.schedule,name:a?.name??e.source,disabled:n,disconnected:e.state===`disconnected`||e.selectedConversations===0,onSave:i}),(0,d.jsxs)(`div`,{className:`settings-button-row`,children:[(0,d.jsx)(`button`,{className:`settings-secondary`,type:`button`,disabled:n||t.running||e.state!==`active`||e.selectedConversations===0,onClick:()=>r(`sync`,e.id),children:`Sync now`}),(0,d.jsx)(`button`,{className:`settings-secondary`,type:`button`,onClick:()=>o({kind:`view`,view:`apps`}),children:`Choose conversations in Connections`}),e.state===`disconnected`?(0,d.jsx)(`button`,{className:`settings-secondary`,type:`button`,disabled:n,onClick:()=>r(`reconnect`,e.id),children:`Reconnect`}):(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)(`button`,{className:`settings-secondary`,type:`button`,disabled:n,onClick:()=>r(e.state===`paused`?`resume`:`pause`,e.id),children:e.state===`paused`?`Resume source`:`Pause source`}),(0,d.jsx)(`button`,{className:`settings-secondary`,type:`button`,disabled:n,onClick:()=>r(`disconnect`,e.id),children:`Disconnect`})]})]})]})}export{h as ConversationImportsSettings};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{i as e}from"./rolldown-runtime-Dd_uD5pT.js";import{g as t,m as n}from"./index-CDtTBysF.js";import{P as r,t as i}from"./useQuery-9SCnxwmR.js";import{M as a,h as o,j as s}from"./chunk-H3JZ3P5T-DolwEJXo.js";import{S as c,_ as l,g as u,m as d,p as f,v as p}from"./LearningBatchesPage-Cm-btgWc.js";import{r as m}from"./chunk-C3TS766N-BXUEjt7d.js";import{At as h,Mn as g,Nn as _}from"./training-CGYukv2L.js";import{nt as v}from"./chunk-GCUWJUUM-Dy6oUNJ6.js";import{n as y}from"./api-client-DJRVOFzS.js";import{n as b,t as x}from"./query-scope-BRpcgljO.js";import{Gt as S,Ut as C}from"./App-CV1p0_Zy.js";import{B as w,W as T,nt as E,z as D}from"./MainPane-BtzUF6O_.js";import{t as O}from"./dataset-workspaces-BTPi71mz.js";var k=e(t(),1),A=n();function j({api:e,release:t,tasks:n,selected:r,onChange:a,disabled:o}){let[s,c]=(0,k.useState)(0),u=new Set(r),d=r.length===n.length?`all`:r.length?[`train`,`validation`,`test`,`frozen_eval`].find(e=>n.every(t=>u.has(t.id)===(t.split===e)))??`custom`:`none`,f=n.slice(s*20,(s+1)*20),m=s?n[s*20-1]?.id:void 0,h=i({queryKey:[`evaluation-workspace`,e.key,x(e.connection),`dataset-review-preview`,t,m],queryFn:async({signal:n})=>{let r=O.parse(await e.request(`datasetPopulation`,{release:t,view:`policy`,limit:20,...m?{afterId:m}:{}},n));if(r.teamId!==e.teamId||v(r.release)!==v(t)||r.view!==`policy`||v(r.items.map(e=>e.id))!==v(f.map(e=>e.id)))throw Error(`The example preview differs from the selected Dataset population.`);return r}}),g=new Map(h.data?.items.map(e=>[e.id,e]));return(0,A.jsxs)(`section`,{children:[(0,A.jsxs)(`label`,{children:[`Examples`,(0,A.jsx)(C,{label:`Dataset examples to import`,floating:!0,value:d,disabled:o,options:[{value:`all`,label:`All examples`},{value:`train`,label:`Training split`},{value:`validation`,label:`Validation split`},{value:`test`,label:`Test split`},{value:`frozen_eval`,label:`Frozen evaluation split`},{value:`none`,label:`None`},...d===`custom`?[{value:`custom`,label:`Custom selection`,disabled:!0}]:[]],onChange:e=>a(n.filter(t=>e===`all`||t.split===e).map(e=>e.id))})]}),(0,A.jsxs)(`p`,{children:[r.length,` of `,n.length,` examples selected. Each example keeps its original split.`]}),(0,A.jsx)(S,{error:h.error}),h.error?(0,A.jsx)(`button`,{type:`button`,className:`training-button secondary`,onClick:()=>void h.refetch(),children:`Retry example previews`}):null,(0,A.jsx)(`div`,{className:`training-table-wrap`,children:(0,A.jsxs)(`table`,{className:`training-data-table evaluation-workspace-table`,children:[(0,A.jsx)(`thead`,{children:(0,A.jsxs)(`tr`,{children:[(0,A.jsx)(`th`,{children:`Select`}),(0,A.jsx)(`th`,{children:`Example`}),(0,A.jsx)(`th`,{children:`Split`})]})}),(0,A.jsx)(`tbody`,{children:f.map((e,t)=>{let n=g.get(e.id),i=n&&`input`in n?n.input:null;return(0,A.jsxs)(`tr`,{children:[(0,A.jsx)(`td`,{children:(0,A.jsx)(`input`,{className:`training-chat-checkbox`,type:`checkbox`,"aria-label":`Import example ${s*20+t+1}`,disabled:o,checked:u.has(e.id),onChange:t=>a(t.target.checked?[...r,e.id]:r.filter(t=>t!==e.id))})}),(0,A.jsx)(`td`,{className:`dataset-review-example`,children:i?(0,A.jsxs)(A.Fragment,{children:[(0,A.jsx)(`span`,{children:p(i)||`Structured input`}),(0,A.jsxs)(`details`,{children:[(0,A.jsx)(`summary`,{children:`Inspect input`}),(0,A.jsx)(l,{value:i}),(0,A.jsx)(`code`,{children:e.id})]})]}):(0,A.jsx)(`span`,{children:h.isPending?`Loading input…`:`Example ${s*20+t+1}`})}),(0,A.jsx)(`td`,{children:e.split.replaceAll(`_`,` `)})]},e.id)})})]})}),(0,A.jsxs)(`div`,{className:`model-build-actions`,children:[s>0?(0,A.jsx)(`button`,{type:`button`,className:`training-button secondary`,onClick:()=>c(e=>e-1),children:`Previous examples`}):null,(s+1)*20<n.length?(0,A.jsx)(`button`,{type:`button`,className:`training-button secondary`,onClick:()=>c(e=>e+1),children:`More examples`}):null]})]})}function M(e,t,n){let i=r(),[a,o]=(0,k.useState)(!1),[s,c]=(0,k.useState)(!1),[l,u]=(0,k.useState)(null),[d,f]=(0,k.useState)(null),p=(0,k.useRef)(!1),m=(0,k.useRef)(!0),_=`${e.key}:${x(e.connection)}`,v=(0,k.useRef)(_);v.current=_;let S=(0,k.useRef)(null);(0,k.useEffect)(()=>(m.current=!0,()=>{m.current=!1}),[]);let C=()=>m.current&&v.current===_;async function w(r){if(!(p.current||d)){p.current=!0,o(!0),u(null);try{if(!e.actorId)throw Error(`Choose an authenticated account before importing examples.`);if(!S.current){let{operationId:t,...i}=g.parse({...r(),operationId:`reviewed-import`});if(await n?.(),!C())return;let a=await e.operation(`training:review-dataset`,i);if(!C())return;S.current={scope:_,operation:a,request:g.parse({...i,operationId:a.id})},c(!0)}let a=S.current;if(!C()||a.scope!==_)throw Error(`The import account changed. Reopen Dataset review.`);let o=await h(await y(e.connection,`/v1/training/setup/review-dataset?teamId=${encodeURIComponent(e.teamId)}`,{method:`POST`,body:JSON.stringify(a.request)}),a.request,e.actorId);if(!C())return;f(o),i.invalidateQueries({queryKey:b(t)});try{await a.operation.acknowledge()}catch(e){C()&&u(e)}}catch(e){C()&&u(e)}finally{p.current=!1,C()&&o(!1)}}}function T(){p.current||d||(S.current=null,c(!1),u(null))}return{busy:a,attempted:s,error:l,receipt:d,submit:w,editSettings:T}}function N({api:e,client:t,source:n,tasks:r,method:i,beforeImport:l,initialSelection:p,onLocked:h,onImported:g}){let[_]=(0,k.useState)(n),[v,y]=(0,k.useState)(()=>p??r.map(e=>e.id)),[b,x]=(0,k.useState)(null),[w,E]=(0,k.useState)(_.definition.instructions??``),[D,O]=(0,k.useState)(_.definition.outputSchema?JSON.stringify(_.definition.outputSchema,null,2):``),[N,P]=(0,k.useState)(i===`grpo`?`none`:`expected_output`),[F,I]=(0,k.useState)(!1),[L,R]=(0,k.useState)(null),z=c(t,`definition`,{limit:30,...L?{afterId:L}:{}}),B=M(e,t,l),V=B.busy||B.attempted||!!B.receipt;(0,k.useEffect)(()=>(h(V),()=>h(!1)),[V,h]);let H=JSON.stringify({selected:v,format:b?a(b):null,instructions:w,output:D,targetSource:N,shared:F}),U=(0,k.useRef)(H),W=T({name:B.attempted?`retained Dataset import request`:`Dataset import`,discardDescription:B.attempted?`This import may already be saved. Retry the original request to recover its receipt. Changing the settings starts a separate import; examples already copied remain in workspace review.`:void 0,busy:B.busy,dirty:!B.receipt&&(H!==U.current||B.attempted)}),G=[...b?[b]:[],...z.page?.items??[]].filter((e,t,n)=>n.findIndex(t=>t.contentHash===e.contentHash)===t);function K(e){let t=G.find(t=>t.contentHash===e)??null;t&&s(t),x(t),E(t?.instructions??_.definition.instructions??``);let n=t?.outputSchema??_.definition.outputSchema;O(n?JSON.stringify(n,null,2):``)}function q(){if(!F)throw Error(`Confirm workspace sharing before copying these examples.`);if(!v.length)throw Error(`Select at least one Dataset example.`);let t=b?.rewardBinding??_.rewardBinding;if(!t)throw Error(`Choose a published task format with a saved Reward.`);if(!w.trim())throw Error(`Provide the actual task instructions.`);if(!D.trim())throw Error(`Provide the actual output schema.`);let n=b?{name:b.name,inputSchema:o.parse(b.inputSchema),...b.requiredOutputs?{requiredOutputs:b.requiredOutputs}:{}}:_.definition;return{schemaVersion:`openpond.datasetTrainingReviewRequest.v1`,teamId:e.teamId,dataset:_.dataset,packageHash:_.packageHash,taskIds:[...v].sort(),purpose:i===`grpo`?`reward_training`:`supervised_training`,rewardBindingRef:t,definition:{...n,instructions:w,outputSchema:u(D)},targetSource:N,shareWithWorkspace:!0}}return(0,A.jsxs)(`form`,{noValidate:!0,onSubmit:e=>{e.preventDefault(),B.submit(q)},children:[(0,A.jsx)(S,{error:B.error??z.error}),B.receipt?(0,A.jsxs)(m,{title:`Imported for review`,children:[(0,A.jsxs)(`p`,{role:`status`,children:[B.receipt.evidence.length,` examples copied · `,B.receipt.proposals.length,` `,`target proposals.`]}),(0,A.jsx)(`p`,{children:`Grade and review the new evidence before sealing a training batch.`}),(0,A.jsx)(`button`,{type:`button`,className:`training-button`,onClick:()=>{B.receipt&&(W.allowNextNavigation(),g(B.receipt))},children:`Review imported examples`})]}):null,(0,A.jsx)(m,{title:`Task format`,children:(0,A.jsxs)(`fieldset`,{disabled:V,children:[(0,A.jsxs)(`label`,{children:[`Task format`,(0,A.jsx)(C,{floating:!0,searchable:!0,label:`Dataset review task format`,value:b?.contentHash??`dataset`,options:[{value:`dataset`,label:_.rewardBinding?`${_.definition.name??`Dataset`} · Dataset format`:`Choose a task format`},...G.map(e=>({value:e.contentHash,label:`${e.name} · release ${e.revision}`}))],onChange:K})]}),(0,A.jsx)(d,{after:L,next:z.page?.nextCursor,onPage:R}),!_.rewardBinding&&!b?(0,A.jsx)(`p`,{children:`Select a published task format to supply its instructions, output schema and Reward. Create one under Import examples if needed.`}):null,b?.instructions&&b.outputSchema||_.definition.instructions&&_.definition.outputSchema?(0,A.jsxs)(`details`,{children:[(0,A.jsx)(`summary`,{children:`Instructions and output contract`}),(0,A.jsxs)(`label`,{children:[`Task instructions`,(0,A.jsx)(`textarea`,{rows:4,value:w,onChange:e=>E(e.target.value)})]}),(0,A.jsx)(f,{label:`Output schema`,value:D,onChange:O})]}):(0,A.jsxs)(A.Fragment,{children:[(0,A.jsxs)(`label`,{children:[`Task instructions`,(0,A.jsx)(`textarea`,{rows:4,value:w,onChange:e=>E(e.target.value)})]}),(0,A.jsx)(f,{label:`Output schema`,value:D,onChange:O})]}),i===`grpo`?null:(0,A.jsxs)(`label`,{children:[`Target proposals`,(0,A.jsx)(C,{label:`Dataset target proposals`,floating:!0,value:N,onChange:e=>P(e),options:[{value:`expected_output`,label:`Dataset answers as proposals`},{value:`none`,label:`No target proposals`},..._.hasParentTargets?[{value:`approved_parent`,label:`Previously approved answers as proposals`}]:[]]})]}),(0,A.jsx)(`p`,{children:`Dataset execution requirements and split boundaries are retained. Imported answers still need fresh grading and approval.`})]})}),(0,A.jsx)(m,{title:`Selected examples`,children:(0,A.jsx)(j,{api:e,release:_.dataset,tasks:r,selected:v,onChange:y,disabled:V})}),(0,A.jsxs)(m,{title:`Workspace sharing`,children:[(0,A.jsxs)(`label`,{className:`learning-inline-choice`,children:[(0,A.jsx)(`input`,{type:`checkbox`,checked:F,disabled:V,onChange:e=>I(e.target.checked)}),` `,`Copy the selected examples into workspace review`]}),(0,A.jsx)(`p`,{children:`Workspace members can read the selected inputs, answers and evaluator context. Required files are retained for grading and training.`})]}),B.receipt?null:(0,A.jsxs)(`div`,{className:`model-build-actions`,children:[(0,A.jsx)(`button`,{type:`submit`,className:`training-button`,disabled:B.busy||!F||!v.length,children:B.busy?`Importing…`:B.attempted?`Retry original import`:`Import for review`}),B.attempted?(0,A.jsx)(`button`,{type:`button`,className:`training-button secondary`,disabled:B.busy,onClick:()=>void W.requestLeave(B.editSettings),children:`Edit import settings`}):null]}),W.dialog]})}function P({api:e,client:t,method:n,beforeImport:r,navigation:a,onImported:o}){let s=E(),[c,l]=(0,k.useState)(()=>s.selection?.release??s.draft?.release??null),[u,d]=(0,k.useState)(!1),f=i({queryKey:[`evaluation-workspace`,e.key,x(e.connection),`dataset-review-source`,c],enabled:!!c,queryFn:async({signal:t})=>{let n=_.parse(await e.request(`datasetReviewSource`,{release:c},t));if(v(n.dataset)!==v(c))throw Error(`Dataset review returned a different release.`);return n}}),p=D(e,c),m=f.data&&p.data&&f.data.taskCount!==p.data.taskCount?Error(`The Dataset review population differs from the retained package.`):null,h=f.error??p.error??m;return(0,A.jsxs)(`section`,{className:`learning-workspace`,children:[(0,A.jsx)(`h3`,{children:`Import a published Dataset`}),(0,A.jsx)(w,{api:e,value:c,disabled:u,onChange:e=>{v(e)!==v(c)&&a.current?.requestLeave(()=>l(e))}}),(0,A.jsx)(S,{error:h}),h?(0,A.jsx)(`button`,{type:`button`,className:`training-button secondary`,disabled:u,onClick:()=>{f.refetch(),p.refetch()},children:`Retry Dataset read`}):null,c&&(!f.data||!p.data)&&!h?(0,A.jsx)(`p`,{role:`status`,children:`Reading the exact Dataset version…`}):null,f.data&&p.data&&!m&&v(f.data.dataset)===v(c)?(0,A.jsx)(N,{api:e,client:t,source:f.data,tasks:p.data.items,method:n,beforeImport:r,initialSelection:s.selection?.release.contentHash===f.data.dataset.contentHash&&s.selection.mode===`subset`?s.selection.ids:null,onLocked:d,onImported:o},`${x(e.connection)}:${f.data.dataset.contentHash}:${n}`):null]})}export{P as default};
|
|
1
|
+
import{i as e}from"./rolldown-runtime-Dd_uD5pT.js";import{g as t,m as n}from"./index-DG0kf1wK.js";import{P as r,t as i}from"./useQuery-CKHqHSr0.js";import{M as a,h as o,j as s}from"./chunk-H3JZ3P5T-DolwEJXo.js";import{S as c,_ as l,g as u,m as d,p as f,v as p}from"./LearningBatchesPage-CpZ0UTX3.js";import{r as m}from"./chunk-C3TS766N-bHAuW3qR.js";import{At as h,Mn as g,Nn as _}from"./training-KYW8yE6p.js";import{nt as v}from"./chunk-GCUWJUUM-Dy6oUNJ6.js";import{n as y}from"./api-client-DJRVOFzS.js";import{n as b,t as x}from"./query-scope-BRpcgljO.js";import{Gt as S,Ut as C}from"./App-CqqK4NLa.js";import{B as w,W as T,nt as E,z as D}from"./MainPane-aEELnEKb.js";import{t as O}from"./dataset-workspaces-DM2zGcAK.js";var k=e(t(),1),A=n();function j({api:e,release:t,tasks:n,selected:r,onChange:a,disabled:o}){let[s,c]=(0,k.useState)(0),u=new Set(r),d=r.length===n.length?`all`:r.length?[`train`,`validation`,`test`,`frozen_eval`].find(e=>n.every(t=>u.has(t.id)===(t.split===e)))??`custom`:`none`,f=n.slice(s*20,(s+1)*20),m=s?n[s*20-1]?.id:void 0,h=i({queryKey:[`evaluation-workspace`,e.key,x(e.connection),`dataset-review-preview`,t,m],queryFn:async({signal:n})=>{let r=O.parse(await e.request(`datasetPopulation`,{release:t,view:`policy`,limit:20,...m?{afterId:m}:{}},n));if(r.teamId!==e.teamId||v(r.release)!==v(t)||r.view!==`policy`||v(r.items.map(e=>e.id))!==v(f.map(e=>e.id)))throw Error(`The example preview differs from the selected Dataset population.`);return r}}),g=new Map(h.data?.items.map(e=>[e.id,e]));return(0,A.jsxs)(`section`,{children:[(0,A.jsxs)(`label`,{children:[`Examples`,(0,A.jsx)(C,{label:`Dataset examples to import`,floating:!0,value:d,disabled:o,options:[{value:`all`,label:`All examples`},{value:`train`,label:`Training split`},{value:`validation`,label:`Validation split`},{value:`test`,label:`Test split`},{value:`frozen_eval`,label:`Frozen evaluation split`},{value:`none`,label:`None`},...d===`custom`?[{value:`custom`,label:`Custom selection`,disabled:!0}]:[]],onChange:e=>a(n.filter(t=>e===`all`||t.split===e).map(e=>e.id))})]}),(0,A.jsxs)(`p`,{children:[r.length,` of `,n.length,` examples selected. Each example keeps its original split.`]}),(0,A.jsx)(S,{error:h.error}),h.error?(0,A.jsx)(`button`,{type:`button`,className:`training-button secondary`,onClick:()=>void h.refetch(),children:`Retry example previews`}):null,(0,A.jsx)(`div`,{className:`training-table-wrap`,children:(0,A.jsxs)(`table`,{className:`training-data-table evaluation-workspace-table`,children:[(0,A.jsx)(`thead`,{children:(0,A.jsxs)(`tr`,{children:[(0,A.jsx)(`th`,{children:`Select`}),(0,A.jsx)(`th`,{children:`Example`}),(0,A.jsx)(`th`,{children:`Split`})]})}),(0,A.jsx)(`tbody`,{children:f.map((e,t)=>{let n=g.get(e.id),i=n&&`input`in n?n.input:null;return(0,A.jsxs)(`tr`,{children:[(0,A.jsx)(`td`,{children:(0,A.jsx)(`input`,{className:`training-chat-checkbox`,type:`checkbox`,"aria-label":`Import example ${s*20+t+1}`,disabled:o,checked:u.has(e.id),onChange:t=>a(t.target.checked?[...r,e.id]:r.filter(t=>t!==e.id))})}),(0,A.jsx)(`td`,{className:`dataset-review-example`,children:i?(0,A.jsxs)(A.Fragment,{children:[(0,A.jsx)(`span`,{children:p(i)||`Structured input`}),(0,A.jsxs)(`details`,{children:[(0,A.jsx)(`summary`,{children:`Inspect input`}),(0,A.jsx)(l,{value:i}),(0,A.jsx)(`code`,{children:e.id})]})]}):(0,A.jsx)(`span`,{children:h.isPending?`Loading input…`:`Example ${s*20+t+1}`})}),(0,A.jsx)(`td`,{children:e.split.replaceAll(`_`,` `)})]},e.id)})})]})}),(0,A.jsxs)(`div`,{className:`model-build-actions`,children:[s>0?(0,A.jsx)(`button`,{type:`button`,className:`training-button secondary`,onClick:()=>c(e=>e-1),children:`Previous examples`}):null,(s+1)*20<n.length?(0,A.jsx)(`button`,{type:`button`,className:`training-button secondary`,onClick:()=>c(e=>e+1),children:`More examples`}):null]})]})}function M(e,t,n){let i=r(),[a,o]=(0,k.useState)(!1),[s,c]=(0,k.useState)(!1),[l,u]=(0,k.useState)(null),[d,f]=(0,k.useState)(null),p=(0,k.useRef)(!1),m=(0,k.useRef)(!0),_=`${e.key}:${x(e.connection)}`,v=(0,k.useRef)(_);v.current=_;let S=(0,k.useRef)(null);(0,k.useEffect)(()=>(m.current=!0,()=>{m.current=!1}),[]);let C=()=>m.current&&v.current===_;async function w(r){if(!(p.current||d)){p.current=!0,o(!0),u(null);try{if(!e.actorId)throw Error(`Choose an authenticated account before importing examples.`);if(!S.current){let{operationId:t,...i}=g.parse({...r(),operationId:`reviewed-import`});if(await n?.(),!C())return;let a=await e.operation(`training:review-dataset`,i);if(!C())return;S.current={scope:_,operation:a,request:g.parse({...i,operationId:a.id})},c(!0)}let a=S.current;if(!C()||a.scope!==_)throw Error(`The import account changed. Reopen Dataset review.`);let o=await h(await y(e.connection,`/v1/training/setup/review-dataset?teamId=${encodeURIComponent(e.teamId)}`,{method:`POST`,body:JSON.stringify(a.request)}),a.request,e.actorId);if(!C())return;f(o),i.invalidateQueries({queryKey:b(t)});try{await a.operation.acknowledge()}catch(e){C()&&u(e)}}catch(e){C()&&u(e)}finally{p.current=!1,C()&&o(!1)}}}function T(){p.current||d||(S.current=null,c(!1),u(null))}return{busy:a,attempted:s,error:l,receipt:d,submit:w,editSettings:T}}function N({api:e,client:t,source:n,tasks:r,method:i,beforeImport:l,initialSelection:p,onLocked:h,onImported:g}){let[_]=(0,k.useState)(n),[v,y]=(0,k.useState)(()=>p??r.map(e=>e.id)),[b,x]=(0,k.useState)(null),[w,E]=(0,k.useState)(_.definition.instructions??``),[D,O]=(0,k.useState)(_.definition.outputSchema?JSON.stringify(_.definition.outputSchema,null,2):``),[N,P]=(0,k.useState)(i===`grpo`?`none`:`expected_output`),[F,I]=(0,k.useState)(!1),[L,R]=(0,k.useState)(null),z=c(t,`definition`,{limit:30,...L?{afterId:L}:{}}),B=M(e,t,l),V=B.busy||B.attempted||!!B.receipt;(0,k.useEffect)(()=>(h(V),()=>h(!1)),[V,h]);let H=JSON.stringify({selected:v,format:b?a(b):null,instructions:w,output:D,targetSource:N,shared:F}),U=(0,k.useRef)(H),W=T({name:B.attempted?`retained Dataset import request`:`Dataset import`,discardDescription:B.attempted?`This import may already be saved. Retry the original request to recover its receipt. Changing the settings starts a separate import; examples already copied remain in workspace review.`:void 0,busy:B.busy,dirty:!B.receipt&&(H!==U.current||B.attempted)}),G=[...b?[b]:[],...z.page?.items??[]].filter((e,t,n)=>n.findIndex(t=>t.contentHash===e.contentHash)===t);function K(e){let t=G.find(t=>t.contentHash===e)??null;t&&s(t),x(t),E(t?.instructions??_.definition.instructions??``);let n=t?.outputSchema??_.definition.outputSchema;O(n?JSON.stringify(n,null,2):``)}function q(){if(!F)throw Error(`Confirm workspace sharing before copying these examples.`);if(!v.length)throw Error(`Select at least one Dataset example.`);let t=b?.rewardBinding??_.rewardBinding;if(!t)throw Error(`Choose a published task format with a saved Reward.`);if(!w.trim())throw Error(`Provide the actual task instructions.`);if(!D.trim())throw Error(`Provide the actual output schema.`);let n=b?{name:b.name,inputSchema:o.parse(b.inputSchema),...b.requiredOutputs?{requiredOutputs:b.requiredOutputs}:{}}:_.definition;return{schemaVersion:`openpond.datasetTrainingReviewRequest.v1`,teamId:e.teamId,dataset:_.dataset,packageHash:_.packageHash,taskIds:[...v].sort(),purpose:i===`grpo`?`reward_training`:`supervised_training`,rewardBindingRef:t,definition:{...n,instructions:w,outputSchema:u(D)},targetSource:N,shareWithWorkspace:!0}}return(0,A.jsxs)(`form`,{noValidate:!0,onSubmit:e=>{e.preventDefault(),B.submit(q)},children:[(0,A.jsx)(S,{error:B.error??z.error}),B.receipt?(0,A.jsxs)(m,{title:`Imported for review`,children:[(0,A.jsxs)(`p`,{role:`status`,children:[B.receipt.evidence.length,` examples copied · `,B.receipt.proposals.length,` `,`target proposals.`]}),(0,A.jsx)(`p`,{children:`Grade and review the new evidence before sealing a training batch.`}),(0,A.jsx)(`button`,{type:`button`,className:`training-button`,onClick:()=>{B.receipt&&(W.allowNextNavigation(),g(B.receipt))},children:`Review imported examples`})]}):null,(0,A.jsx)(m,{title:`Task format`,children:(0,A.jsxs)(`fieldset`,{disabled:V,children:[(0,A.jsxs)(`label`,{children:[`Task format`,(0,A.jsx)(C,{floating:!0,searchable:!0,label:`Dataset review task format`,value:b?.contentHash??`dataset`,options:[{value:`dataset`,label:_.rewardBinding?`${_.definition.name??`Dataset`} · Dataset format`:`Choose a task format`},...G.map(e=>({value:e.contentHash,label:`${e.name} · release ${e.revision}`}))],onChange:K})]}),(0,A.jsx)(d,{after:L,next:z.page?.nextCursor,onPage:R}),!_.rewardBinding&&!b?(0,A.jsx)(`p`,{children:`Select a published task format to supply its instructions, output schema and Reward. Create one under Import examples if needed.`}):null,b?.instructions&&b.outputSchema||_.definition.instructions&&_.definition.outputSchema?(0,A.jsxs)(`details`,{children:[(0,A.jsx)(`summary`,{children:`Instructions and output contract`}),(0,A.jsxs)(`label`,{children:[`Task instructions`,(0,A.jsx)(`textarea`,{rows:4,value:w,onChange:e=>E(e.target.value)})]}),(0,A.jsx)(f,{label:`Output schema`,value:D,onChange:O})]}):(0,A.jsxs)(A.Fragment,{children:[(0,A.jsxs)(`label`,{children:[`Task instructions`,(0,A.jsx)(`textarea`,{rows:4,value:w,onChange:e=>E(e.target.value)})]}),(0,A.jsx)(f,{label:`Output schema`,value:D,onChange:O})]}),i===`grpo`?null:(0,A.jsxs)(`label`,{children:[`Target proposals`,(0,A.jsx)(C,{label:`Dataset target proposals`,floating:!0,value:N,onChange:e=>P(e),options:[{value:`expected_output`,label:`Dataset answers as proposals`},{value:`none`,label:`No target proposals`},..._.hasParentTargets?[{value:`approved_parent`,label:`Previously approved answers as proposals`}]:[]]})]}),(0,A.jsx)(`p`,{children:`Dataset execution requirements and split boundaries are retained. Imported answers still need fresh grading and approval.`})]})}),(0,A.jsx)(m,{title:`Selected examples`,children:(0,A.jsx)(j,{api:e,release:_.dataset,tasks:r,selected:v,onChange:y,disabled:V})}),(0,A.jsxs)(m,{title:`Workspace sharing`,children:[(0,A.jsxs)(`label`,{className:`learning-inline-choice`,children:[(0,A.jsx)(`input`,{type:`checkbox`,checked:F,disabled:V,onChange:e=>I(e.target.checked)}),` `,`Copy the selected examples into workspace review`]}),(0,A.jsx)(`p`,{children:`Workspace members can read the selected inputs, answers and evaluator context. Required files are retained for grading and training.`})]}),B.receipt?null:(0,A.jsxs)(`div`,{className:`model-build-actions`,children:[(0,A.jsx)(`button`,{type:`submit`,className:`training-button`,disabled:B.busy||!F||!v.length,children:B.busy?`Importing…`:B.attempted?`Retry original import`:`Import for review`}),B.attempted?(0,A.jsx)(`button`,{type:`button`,className:`training-button secondary`,disabled:B.busy,onClick:()=>void W.requestLeave(B.editSettings),children:`Edit import settings`}):null]}),W.dialog]})}function P({api:e,client:t,method:n,beforeImport:r,navigation:a,onImported:o}){let s=E(),[c,l]=(0,k.useState)(()=>s.selection?.release??s.draft?.release??null),[u,d]=(0,k.useState)(!1),f=i({queryKey:[`evaluation-workspace`,e.key,x(e.connection),`dataset-review-source`,c],enabled:!!c,queryFn:async({signal:t})=>{let n=_.parse(await e.request(`datasetReviewSource`,{release:c},t));if(v(n.dataset)!==v(c))throw Error(`Dataset review returned a different release.`);return n}}),p=D(e,c),m=f.data&&p.data&&f.data.taskCount!==p.data.taskCount?Error(`The Dataset review population differs from the retained package.`):null,h=f.error??p.error??m;return(0,A.jsxs)(`section`,{className:`learning-workspace`,children:[(0,A.jsx)(`h3`,{children:`Import a published Dataset`}),(0,A.jsx)(w,{api:e,value:c,disabled:u,onChange:e=>{v(e)!==v(c)&&a.current?.requestLeave(()=>l(e))}}),(0,A.jsx)(S,{error:h}),h?(0,A.jsx)(`button`,{type:`button`,className:`training-button secondary`,disabled:u,onClick:()=>{f.refetch(),p.refetch()},children:`Retry Dataset read`}):null,c&&(!f.data||!p.data)&&!h?(0,A.jsx)(`p`,{role:`status`,children:`Reading the exact Dataset version…`}):null,f.data&&p.data&&!m&&v(f.data.dataset)===v(c)?(0,A.jsx)(N,{api:e,client:t,source:f.data,tasks:p.data.items,method:n,beforeImport:r,initialSelection:s.selection?.release.contentHash===f.data.dataset.contentHash&&s.selection.mode===`subset`?s.selection.ids:null,onLocked:d,onImported:o},`${x(e.connection)}:${f.data.dataset.contentHash}:${n}`):null]})}export{P as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/DatasetReviewImport
|
|
2
|
-
import{i as e}from"./rolldown-runtime-Dd_uD5pT.js";import{g as t,m as n,t as r}from"./index-
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/DatasetReviewImport--FgZ3Zk-.js","assets/rolldown-runtime-Dd_uD5pT.js","assets/index-DG0kf1wK.js","assets/index-g7UqJhnX.css","assets/useQuery-CKHqHSr0.js","assets/chunk-H3JZ3P5T-DolwEJXo.js","assets/schemas-Brv9Vmnk.js","assets/common-BWVSBnpX.js","assets/LearningBatchesPage-CpZ0UTX3.js","assets/reward-checks-DJJZYgf8.js","assets/chunk-C3TS766N-bHAuW3qR.js","assets/model-display-zPvC4L2B.js","assets/intake-contracts-B8JZKYwb.js","assets/app-models-BUdzQbXo.js","assets/settings-BC-bzgk6.js","assets/icons-nr5d1kC-.js","assets/loader-circle-C1-u7BUs.js","assets/x-CQ0pGF6Q.js","assets/App-CqqK4NLa.js","assets/client-choice-storage-D_6dVX8O.js","assets/api-client-DJRVOFzS.js","assets/requests-DmeUYik4.js","assets/create-pipeline-DsZzNkt9.js","assets/profile-ref-D8lxL7dW.js","assets/work-outputs-D_8TovAK.js","assets/chunk-GS5HEE4M-DTj6NX5d.js","assets/chunk-GCUWJUUM-Dy6oUNJ6.js","assets/training-KYW8yE6p.js","assets/chunk-Q4RGCEOI-Cr-dg4Nk.js","assets/ponder-desktop-Ca-9KggQ.js","assets/chat-resources-BFT0vtdv.js","assets/submit-issue-command-wDL6xK3b.js","assets/connected-app-mentions-D3wRZLwI.js","assets/profile-agent-labels-Duh96b8x.js","assets/browser-sidebar-links-PVPCrsDJ.js","assets/browser-url-LACq2Ngu.js","assets/query-scope-BRpcgljO.js","assets/bot-C0e4zzW4.js","assets/chevron-down-C4LIbeSz.js","assets/chevron-right-BKelERU6.js","assets/copy-B0gWkglr.js","assets/external-link-DymjzX8a.js","assets/maximize-2-B2pi1o5S.js","assets/message-square-CPvsC3Wv.js","assets/plus-D6oFNFQ0.js","assets/refresh-cw-avBifyns.js","assets/square-terminal-D7snuW2g.js","assets/AppToastContext-DyaZYQXu.js","assets/NativeSetupTerminal-BXvrxj-m.js","assets/AppDialog-wmL4BlOJ.js","assets/PageChrome-BXMG877B.js","assets/NativeSetupTerminal-3eR9D_R3.css","assets/organization-types-PP-yuR2J.js","assets/ui-theme.generated-D-mc26qt.js","assets/App-DpFKLxuA.css","assets/ModelProjectPageHeader-BVwW-R0w.js","assets/MainPane-aEELnEKb.js","assets/useChatContextSelection-CBVI5IYj.js","assets/ComposerAttachments-BOyEXVhV.js","assets/training-model-data-CilS0W2N.js","assets/AttachmentTypeIcon-AqiS2gzg.js","assets/presentation-DbkiE2BE.js","assets/image-Us0M7Xxi.js","assets/LabModelWorkspace-Di_yTjzH.js","assets/CartesianChart-C5ptcXRG.js","assets/LabModelWorkspace-DOrgCk9Z.css","assets/cloud-upload-U0f9MSd8.js","assets/folder-open-BPA5YifJ.js","assets/paperclip-CNTReC0m.js","assets/play-DF5h_-8T.js","assets/square-CJccmW-i.js","assets/MainPane-BZlNLfTM.css","assets/LearningBatchesPage-B1NZTBSv.css","assets/dataset-workspaces-DM2zGcAK.js","assets/chunk-AG6UJ3DI-D9KZjTYP.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{i as e}from"./rolldown-runtime-Dd_uD5pT.js";import{g as t,m as n,t as r}from"./index-DG0kf1wK.js";import{P as i,v as a}from"./useQuery-CKHqHSr0.js";import{n as o,r as s,t as c}from"./LearningBatchesPage-CpZ0UTX3.js";import{n as l}from"./query-scope-BRpcgljO.js";import{n as u}from"./PageChrome-BXMG877B.js";import{Ut as d}from"./App-CqqK4NLa.js";import{G as f,K as p,L as m}from"./MainPane-aEELnEKb.js";var h=e(t(),1);function g(e,t){let n=i(t),r=n.getQueryCache();return h.useSyncExternalStore(h.useCallback(e=>r.subscribe(a.batchCalls(e)),[r]),()=>n.isFetching(e),()=>n.isFetching(e))}var _=n(),v=(0,h.lazy)(()=>r(()=>import(`./DatasetReviewImport--FgZ3Zk-.js`),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74])));function y({api:e,method:t,onClose:n,onUseBatch:r,navigation:a,beforeImport:y}){let b=m(e),x=i(),S=l(b),C=g({queryKey:S}),w=g({queryKey:[`evaluation-workspace`,e.key]}),[T,E]=(0,h.useState)(`dataset`),[D,O]=(0,h.useState)(null),[k,A]=(0,h.useState)(null),[j,M]=(0,h.useState)(null),N=e=>{a.current?.requestLeave(e)},P=(e,t=null,n=null)=>N(()=>{E(e),O(t),A(n),M(null)}),F=()=>N(n);return(0,_.jsxs)(p,{label:`Experiment training data`,action:`experiment`,onRequestClose:F,children:[(0,_.jsxs)(`header`,{className:`experiment-training-data-header`,children:[(0,_.jsx)(`h2`,{children:`Training data`}),(0,_.jsx)(`button`,{type:`button`,disabled:C+w>0,onClick:()=>{Promise.all([x.invalidateQueries({queryKey:S}),x.invalidateQueries({queryKey:[`evaluation-workspace`,e.key]})])},children:`Refresh`}),(0,_.jsx)(`button`,{type:`button`,onClick:F,children:`Back to experiment`})]}),(0,_.jsx)(`p`,{children:`Import a Dataset or example records, review them, then select a sealed batch. Your experiment settings stay open.`}),(0,_.jsxs)(`label`,{children:[`View`,(0,_.jsx)(d,{floating:!0,label:`Training data view`,value:T,onChange:e=>P(e),options:[{value:`dataset`,label:`Published Dataset`},{value:`formats`,label:`Import examples`},{value:`review`,label:`Review examples`},{value:`batches`,label:`Reviewed batches`}]})]}),(0,_.jsx)(f,{handle:a,children:(0,_.jsx)(`div`,{className:`experiment-training-data-workspace`,children:(0,_.jsx)(u,{children:T===`dataset`?(0,_.jsx)(h.Suspense,{fallback:(0,_.jsx)(`p`,{role:`status`,children:`Opening Dataset import…`}),children:(0,_.jsx)(v,{api:e,client:b,method:t,beforeImport:y,navigation:a,onImported:e=>P(`review`,null,e.source.id)})}):T===`formats`?(0,_.jsx)(s,{client:b,selectedId:D,after:j,allowCredentials:!1,onSelect:e=>P(`formats`,e),onPage:e=>N(()=>M(e)),onReview:e=>P(`review`,e)}):T===`review`?(0,_.jsx)(o,{client:b,selectedId:D,sourceId:k,onClearSource:()=>P(`review`),after:j,onSelect:e=>P(`review`,e,k),onPage:e=>N(()=>M(e)),onBatches:()=>P(`batches`)}):(0,_.jsx)(c,{client:b,selectedId:D,after:j,purpose:t===`grpo`?`reward_training`:`supervised_training`,onSelect:e=>P(`batches`,e),onPage:e=>N(()=>M(e)),onUseBatch:r})})})})]})}export{y as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/aiden0z-pptx-renderer.es-Bo43EjzT.js","assets/rolldown-runtime-Dd_uD5pT.js","assets/jszip.min-BWcKrrYP.js","assets/pdf-
|
|
2
|
-
import{i as e}from"./rolldown-runtime-Dd_uD5pT.js";import{g as t,m as n,t as r}from"./index-
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/aiden0z-pptx-renderer.es-Bo43EjzT.js","assets/rolldown-runtime-Dd_uD5pT.js","assets/jszip.min-BWcKrrYP.js","assets/pdf-DaNAfjLW.js","assets/index-DG0kf1wK.js","assets/index-g7UqJhnX.css","assets/docx-preview-Blk_WGfs.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{i as e}from"./rolldown-runtime-Dd_uD5pT.js";import{g as t,m as n,t as r}from"./index-DG0kf1wK.js";import"./icons-nr5d1kC-.js";import{U as i,un as a}from"./App-CqqK4NLa.js";import{t as o}from"./pdf.worker.min-BrEVksTu.js";var s=e(t(),1);function c(e=()=>new Promise(e=>setTimeout(e,0))){let t=Promise.resolve();return(n,r)=>{let i=t.then(async()=>{if(n.aborted||(await e(),n.aborted))return;let t=()=>{},i=new Promise(e=>{t=e,n.addEventListener(`abort`,t,{once:!0})});try{await Promise.race([r(),i])}finally{n.removeEventListener(`abort`,t)}});return t=i.catch(()=>{}),i}}var l=c(),u=n();function d({file:e,thumbnail:t=!0}){let n=(0,s.useRef)(null),c=`word-preview-${(0,s.useId)().replace(/[^a-z0-9]/gi,``)}`,[d,f]=(0,s.useState)(!1),[p,m]=(0,s.useState)(!1);return(0,s.useEffect)(()=>{let a=n.current;if(!a||!e.content)return;let s=new AbortController,u=document.createElement(`div`);a.replaceChildren(u);let d=[];f(!1),m(!1);let p=()=>{let e=u.offsetWidth;if(!e)return;let n=u.scrollHeight,r=t?a.parentElement?.clientHeight??0:0,i=t&&r&&n?Math.min(a.clientWidth/e,r/n):a.clientWidth/e;u.style.zoom=String(i)},h=new ResizeObserver(p);h.observe(a),t&&a.parentElement&&h.observe(a.parentElement);let g=async()=>{let n=Uint8Array.from(atob(e.content),e=>e.charCodeAt(0));if(i(e)){let{PptxViewer:e,RECOMMENDED_ZIP_LIMITS:t}=await r(async()=>{let{PptxViewer:e,RECOMMENDED_ZIP_LIMITS:t}=await import(`./aiden0z-pptx-renderer.es-Bo43EjzT.js`);return{PptxViewer:e,RECOMMENDED_ZIP_LIMITS:t}},__vite__mapDeps([0,1,2]));if(s.signal.aborted)return;u.style.width=`320px`;let i=new e(u,{width:320,zipLimits:t,lazySlides:!0,lazyMedia:!0,pdfjs:!1});d.push(()=>i.destroy()),await i.open(n,{signal:s.signal,renderMode:`slide`})}else if(/\.pdf$/i.test(e.path)){let e=await r(()=>import(`./pdf-DaNAfjLW.js`),__vite__mapDeps([3,4,1,5]));if(s.signal.aborted)return;e.GlobalWorkerOptions.workerSrc=o;let t=e.getDocument({data:n});d.push(()=>{t.destroy().catch(()=>{})});let i=await t.promise;if(s.signal.aborted)return;let a=await i.getPage(1),c=a.getViewport({scale:320/a.getViewport({scale:1}).width}),l=document.createElement(`canvas`);l.width=c.width,l.height=c.height,u.style.width=`320px`,u.appendChild(l);let f=a.render({canvas:l,viewport:c});d.push(()=>f.cancel()),await f.promise}else{let[{renderAsync:e},{parseZipLazyMedia:i,RECOMMENDED_ZIP_LIMITS:a}]=await Promise.all([r(()=>import(`./docx-preview-Blk_WGfs.js`),__vite__mapDeps([6,1,2])),r(()=>import(`./aiden0z-pptx-renderer.es-Bo43EjzT.js`),__vite__mapDeps([0,1,2]))]);if(await i(n.buffer,a),s.signal.aborted)return;u.style.width=`816px`,await e(n,u,u,{className:c,inWrapper:!1,breakPages:!0,useBase64URL:!0,renderHeaders:!0,renderFooters:!0,renderFootnotes:!t,renderEndnotes:!t}),t&&Array.from(u.querySelectorAll(`section.${c}`)).slice(1).forEach(e=>e.remove())}s.signal.aborted||(p(),f(!0))};return(t?l(s.signal,g):g()).catch(()=>{s.signal.aborted||m(!0)}),()=>{s.abort(),h.disconnect(),d.reverse().forEach(e=>e()),u.remove()}},[c,e.content,e.path,t]),(0,u.jsxs)(`div`,{className:`file-page-preview ${t?`thumbnail`:`document`}`,children:[d?null:(0,u.jsx)(`span`,{className:`file-page-preview-placeholder`,role:t?void 0:`status`,children:t?(0,u.jsx)(a,{size:28}):p?`Preview unavailable. Download the original document to open it.`:`Loading document…`}),(0,u.jsx)(`div`,{ref:n,className:`file-page-preview-content ${d&&!p?`ready`:``}`})]})}export{d as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{i as e}from"./rolldown-runtime-Dd_uD5pT.js";import{a as t,d as n,f as r,g as i,h as a,i as o,m as s,o as c,r as l,u}from"./index-CDtTBysF.js";import{a as d,n as f}from"./client-choice-storage-DWIA0Vou.js";import"./icons-CYvTltSH.js";import{V as p}from"./training-model-data-vvvphDlO.js";import{t as m}from"./play-BrvX67t1.js";import{t as h}from"./x-EG07vYCF.js";import{t as g}from"./AppDialog-DdGt7aU1.js";import{Cn as _}from"./App-CV1p0_Zy.js";var v=e(i(),1),ee=a(),y=s();function te({badge:e,onPlay:t,titleElement:n=`h3`,video:r}){let[i,a]=(0,v.useState)(!1),o=(0,v.useRef)(null),s=n,c=`${r.id}-title`;function l(){if(t){t();return}(0,ee.flushSync)(()=>a(!0));let e=o.current;e&&(e.load(),e.play().catch(()=>void 0))}return(0,y.jsxs)(y.Fragment,{children:[(0,y.jsxs)(`article`,{className:`get-started-course-card`,"aria-labelledby":c,children:[(0,y.jsx)(`button`,{"aria-haspopup":`dialog`,"aria-label":`Play ${r.title}`,className:`get-started-course-open`,onClick:l,type:`button`}),(0,y.jsxs)(`div`,{className:`get-started-course-media`,children:[(0,y.jsx)(`img`,{alt:``,className:`get-started-course-poster`,decoding:`async`,src:r.posterUrl}),(0,y.jsx)(`span`,{className:`get-started-course-play-icon`,"aria-hidden":`true`,children:(0,y.jsx)(m,{fill:`currentColor`,size:19})}),e?(0,y.jsx)(`span`,{className:`get-started-course-badge`,"aria-hidden":`true`,children:e}):null]}),(0,y.jsxs)(`div`,{className:`get-started-course-copy`,children:[(0,y.jsx)(s,{id:c,children:r.title}),(0,y.jsxs)(`div`,{className:`get-started-course-meta`,"aria-label":`${r.title} details`,children:[(0,y.jsx)(`span`,{children:r.eyebrow}),(0,y.jsx)(`span`,{"aria-hidden":`true`,children:`·`}),(0,y.jsx)(`span`,{children:r.duration})]}),r.description?(0,y.jsx)(`p`,{children:r.description}):null]})]}),i&&!t?(0,y.jsx)(b,{onClose:()=>a(!1),video:r,videoRef:o}):null]})}function b({autoAdvance:e=!1,contained:t=!1,inertExclusionSelector:n,navigation:r,onEnded:i,onClose:a,onPause:o,onTimeUpdate:s,video:c,videoRef:l}){return(0,y.jsxs)(g,{ariaLabel:`${c.title} player`,backdropClassName:`get-started-course-player-backdrop`,className:`get-started-course-player`,contained:t,inertExclusionSelector:n,onClose:a,children:[(0,y.jsxs)(`header`,{className:`get-started-course-player-header`,children:[(0,y.jsxs)(`div`,{className:`get-started-course-player-copy`,children:[(0,y.jsx)(`strong`,{children:c.title}),(0,y.jsxs)(`span`,{children:[r?`Lesson ${r.currentIndex+1} of ${r.total}`:c.eyebrow,` · `,c.duration]})]}),(0,y.jsxs)(`div`,{className:`get-started-course-player-actions`,children:[r?(0,y.jsxs)(y.Fragment,{children:[(0,y.jsx)(`button`,{"aria-label":`Previous lesson`,disabled:!r.onPrevious,onClick:r.onPrevious,title:`Previous lesson`,type:`button`,children:(0,y.jsx)(_,{size:17})}),(0,y.jsx)(`button`,{"aria-label":`Next lesson`,disabled:!r.onNext,onClick:r.onNext,title:`Next lesson`,type:`button`,children:(0,y.jsx)(p,{size:17})})]}):null,(0,y.jsx)(`button`,{"aria-label":`Close video player`,"data-autofocus":!0,onClick:a,title:`Close`,type:`button`,children:(0,y.jsx)(h,{size:18})})]})]}),(0,y.jsx)(`div`,{className:`get-started-course-player-body`,children:(0,y.jsx)(`div`,{className:`get-started-course-player-media`,children:(0,y.jsx)(`div`,{className:`get-started-course-player-stage`,children:(0,y.jsx)(`video`,{"aria-label":`${c.title} video`,className:`get-started-course-player-video`,controls:!0,"data-auto-advance":e?`true`:void 0,onEnded:e=>i?.(e.currentTarget),onPause:e=>o?.(e.currentTarget),onTimeUpdate:e=>s?.(e.currentTarget),playsInline:!0,poster:c.posterUrl,preload:`metadata`,ref:l,src:c.videoUrl,children:c.captionsUrl?(0,y.jsx)(`track`,{kind:`captions`,label:`English`,src:c.captionsUrl,srcLang:`en`}):null},c.id)})})})]})}var x={schemaVersion:`openpond.publicVideoManifest.v1`,playlists:[{id:`post-training-from-first-principles`,fullVideoId:`post-training-full-course`,status:`draft`,title:`Post-training from first principles`,videoIds:[`post-training-01-how-post-training-works`,`post-training-02-definitions`,`post-training-03-on-policy-off-policy`,`post-training-04-rewards-credit-assignment`,`post-training-05-verifiable-rewards-rlvr`,`post-training-06-ppo-grpo`,`post-training-07-distillation`,`post-training-08-opsd-sdft-sdpo`,`post-training-09-credible-experiments`,`post-training-10-technical-appendix`]},{id:`how-to-make-an-agent`,status:`published`,title:`Agents`,playAllVideoId:`make-agent-tutorial`,videoIds:[`make-agent-tutorial-create`,`make-agent-tutorial-use`,`make-agent-tutorial-improve`]}],videos:[{id:`post-training-01-how-post-training-works`,localPath:`courses/post-training/01-how-post-training-works.mp4`,objectKey:`media/videos/aeb54dfb42eb940672df6e41bae075ffa5e45e1609e173a91e485c808b61fd4a.mp4`,sha256:`aeb54dfb42eb940672df6e41bae075ffa5e45e1609e173a91e485c808b61fd4a`,sizeBytes:2114638,durationSeconds:64.967},{id:`post-training-02-definitions`,localPath:`courses/post-training/02-definitions.mp4`,objectKey:`media/videos/c57d021989cdf058c683b9d017eb91bd23075e6bd00d0cc055e1285b3ea119fc.mp4`,sha256:`c57d021989cdf058c683b9d017eb91bd23075e6bd00d0cc055e1285b3ea119fc`,sizeBytes:11956956,durationSeconds:374.367},{id:`post-training-03-on-policy-off-policy`,localPath:`courses/post-training/03-on-policy-off-policy.mp4`,objectKey:`media/videos/a807bd7d704f8603addc875623a3cfcc938e60e0170d555d47569394a1c31762.mp4`,sha256:`a807bd7d704f8603addc875623a3cfcc938e60e0170d555d47569394a1c31762`,sizeBytes:2291518,durationSeconds:66.367},{id:`post-training-04-rewards-credit-assignment`,localPath:`courses/post-training/04-rewards-credit-assignment.mp4`,objectKey:`media/videos/685f7ecff7fcea262dd2cf60568079633816e9116efd80c069d0e20a4959a87f.mp4`,sha256:`685f7ecff7fcea262dd2cf60568079633816e9116efd80c069d0e20a4959a87f`,sizeBytes:5677418,durationSeconds:179.834},{id:`post-training-05-verifiable-rewards-rlvr`,localPath:`courses/post-training/05-verifiable-rewards-rlvr.mp4`,objectKey:`media/videos/0633584b2036843edd1ff9c63f0858db4272ddf55b10b160ec2ef6f7650c7d3a.mp4`,sha256:`0633584b2036843edd1ff9c63f0858db4272ddf55b10b160ec2ef6f7650c7d3a`,sizeBytes:5666892,durationSeconds:172.534},{id:`post-training-06-ppo-grpo`,localPath:`courses/post-training/06-ppo-grpo.mp4`,objectKey:`media/videos/66760fec7508c413844adb06c3f3920c5f7e3a874b18dc244ba090c55f452ff3.mp4`,sha256:`66760fec7508c413844adb06c3f3920c5f7e3a874b18dc244ba090c55f452ff3`,sizeBytes:5519257,durationSeconds:173.6},{id:`post-training-07-distillation`,localPath:`courses/post-training/07-distillation.mp4`,objectKey:`media/videos/3590f94325c1986f2025b42d182f04957e9eff6d5c06b1effc28dc369651c466.mp4`,sha256:`3590f94325c1986f2025b42d182f04957e9eff6d5c06b1effc28dc369651c466`,sizeBytes:4687640,durationSeconds:161.667},{id:`post-training-08-opsd-sdft-sdpo`,localPath:`courses/post-training/08-opsd-sdft-sdpo.mp4`,objectKey:`media/videos/3c45d8c1df0a24132ec425762dc6a4274b1e5cac6dfd220a2994f8754f431031.mp4`,sha256:`3c45d8c1df0a24132ec425762dc6a4274b1e5cac6dfd220a2994f8754f431031`,sizeBytes:5439835,durationSeconds:163.134},{id:`post-training-09-credible-experiments`,localPath:`courses/post-training/09-credible-experiments.mp4`,objectKey:`media/videos/fc701a8ba4b42de53bcaec3dcf191e6ec66f1dc0c48480f0aff01c3849aff023.mp4`,sha256:`fc701a8ba4b42de53bcaec3dcf191e6ec66f1dc0c48480f0aff01c3849aff023`,sizeBytes:6909405,durationSeconds:211.934},{id:`post-training-10-technical-appendix`,localPath:`courses/post-training/10-technical-appendix.mp4`,objectKey:`media/videos/17e6b5ef161fcdc97678e5b63650bffdb4b4b0d510ba75725a2af8a5db0d7e21.mp4`,sha256:`17e6b5ef161fcdc97678e5b63650bffdb4b4b0d510ba75725a2af8a5db0d7e21`,sizeBytes:5481950,durationSeconds:191.767},{id:`post-training-full-course`,localPath:`courses/post-training/full-course.mp4`,objectKey:`media/videos/d3df6a3b2ffe6c696b9dc0774ceaec19a2b8a92b170476cacb9df8dbdb2a526f.mp4`,sha256:`d3df6a3b2ffe6c696b9dc0774ceaec19a2b8a92b170476cacb9df8dbdb2a526f`,sizeBytes:55740426,durationSeconds:1760.192},{id:`openpond-agent-overview`,localPath:`tutorials/what-is-an-openpond-agent.mp4`,objectKey:`media/videos/421160f56d82abd6515df0d5ccf144591749e0ab1d58d630805c4807913812c7.mp4`,sha256:`421160f56d82abd6515df0d5ccf144591749e0ab1d58d630805c4807913812c7`,sizeBytes:5259848,durationSeconds:77.467},{id:`make-agent-tutorial`,localPath:`tutorials/how-to-make-an-agent.mp4`,objectKey:`media/videos/252d2f27076c904d85c9854c2f4c494fe9e92b3cea7d2c58ffbaa0323c17f255.mp4`,sha256:`252d2f27076c904d85c9854c2f4c494fe9e92b3cea7d2c58ffbaa0323c17f255`,sizeBytes:17339101,durationSeconds:273.067},{id:`make-agent-tutorial-create`,localPath:`tutorials/how-to-make-an-agent-create.mp4`,objectKey:`media/videos/322c999225d4759c34334eee22edee25a737fb06c5c6d66ee1f84485bb586c44.mp4`,sha256:`322c999225d4759c34334eee22edee25a737fb06c5c6d66ee1f84485bb586c44`,sizeBytes:6050301,durationSeconds:100.4},{id:`make-agent-tutorial-use`,localPath:`tutorials/how-to-make-an-agent-use.mp4`,objectKey:`media/videos/6e28bb710f90de8968fa18f996973b869e6748797739dd93cce49d8fbba564c1.mp4`,sha256:`6e28bb710f90de8968fa18f996973b869e6748797739dd93cce49d8fbba564c1`,sizeBytes:5084394,durationSeconds:75.1},{id:`make-agent-tutorial-improve`,localPath:`tutorials/how-to-make-an-agent-improve.mp4`,objectKey:`media/videos/fe8b62bf6ed5f5b933b0023dfdd9a06e69b5b352d4c702b671ec7677b395d58d.mp4`,sha256:`fe8b62bf6ed5f5b933b0023dfdd9a06e69b5b352d4c702b671ec7677b395d58d`,sizeBytes:6255324,durationSeconds:108.634}]},S=`https://media.openpond.ai`,C=x,ne=new Map(C.playlists.map(e=>[e.id,e])),re=new Map(C.videos.map(e=>[e.id,e]));function w(e){let t=ne.get(e);if(!t)throw Error(`Public video manifest is missing playlist ${e}`);return t}function ie(e,t){return t?`${S}/${e.objectKey}`:r(e.localPath)}function T(e){let t=re.get(e);if(!t)throw Error(`Public video manifest is missing ${e}`);return ie(t,!0)}var ae=T(`make-agent-tutorial`),E=T(`openpond-agent-overview`);function oe(e){return T(`make-agent-tutorial-${e}`)}var D={schemaVersion:`openpond.tutorialFrames.v2`,tutorial:{title:`How to make an agent`,subtitle:`Create, run, improve, and verify an Account Health Agent.`,outroTitle:`Agent shared from the hosted Profile`,outroSubtitle:`Available to teammates and hosted sandboxes. · Synthetic tutorial data · AI-generated narration`,narration:{model:`gpt-4o-mini-tts-2025-12-15`,voice:`cedar`,speed:1.12,responseFormat:`wav`,instructions:`Warm, clear product tutorial narration. Speak at a calm conversational pace with practical emphasis on user choices, evidence, approvals, and results. Pronounce OpenPond as open pond, P1 as P one, CSV as C S V, JSON as jay son, and Taskset as task set. Finish each sentence cleanly. Avoid hype, sales cadence, dramatic delivery, or imitation of any real person.`,leadInSeconds:.55,tailSeconds:.7,audioTitle:`AI-generated narration`,audioCredit:`OpenAI Speech · Cedar voice`}},chapters:[{id:`create`,label:`Create`,title:`Create an Agent`,subtitle:`Turn a plain-language purpose into a working Account Health Agent.`,outroTitle:`Account Health Agent created`,outroSubtitle:`The agent is ready to use. · AI-generated narration`,cardDuration:1.5},{id:`use`,label:`Use`,title:`Use the Agent`,subtitle:`Chat with the Account Health Agent and run its actions with approval.`,outroTitle:`First agent run complete`,outroSubtitle:`The result and supporting evidence are ready to review. · AI-generated narration`,cardDuration:1.5},{id:`improve`,label:`Improve`,title:`Improve the Agent`,subtitle:`Use real run evidence and Evals to make the Account Health Agent better.`,outroTitle:`Account Health Agent improved`,outroSubtitle:`The updated agent passed its Evals. · AI-generated narration`,cardDuration:1.5}],transitionDuration:.33,frames:[{id:`C01`,file:`C01-account-agent-lab-create-menu.png`,chapter:`create`,label:`Start in Profile`,caption:`Open Profile, choose Agent, and start the guided creation flow.`,placement:`bottom-left`,narration:`Open Profile, choose Agent, and start the guided creation flow.`,focus:{x:.84,y:.06,width:.145,height:.31,zoom:1.55}},{id:`C02`,file:`C02-source-choice-wide.png`,chapter:`create`,label:`Start from a prompt or chats`,caption:`Choose From prompt to describe the Agent directly, or From chats to include examples of the work it should handle.`,placement:`bottom-left`,narration:`Choose From prompt to describe the Agent directly, or From chats to include examples of the work it should handle.`,focus:{x:.31,y:.34,width:.38,height:.31,zoom:1.42}},{id:`C04`,file:`C04-from-chats-wide.png`,chapter:`create`,label:`Add purpose and chats`,caption:`This synthetic example starts with three chats: Acme has renewal blockers, Northstar is expanding, and the team needs a weekly account review. Add them with the Agent purpose.`,placement:`top-left`,narration:`This synthetic example starts with three chats: Acme has renewal blockers, Northstar is expanding, and the team needs a weekly account review. Add them with the Agent purpose.`,focus:{x:.31,y:.2,width:.38,height:.6,zoom:1.32}},{id:`C06`,file:`C06-disclosure.png`,chapter:`create`,label:`See how chats build the plan`,caption:`Review the selected excerpts as examples. OpenPond turns their recurring goals, decisions, corrections, and answer patterns into the first Agent plan.`,placement:`bottom-left`,narration:`Review the selected excerpts as examples. OpenPond turns their recurring goals, decisions, corrections, and answer patterns into the first Agent plan.`,focus:{x:.31,y:.2,width:.38,height:.6,zoom:1.32}},{id:`C07`,file:`C07-agent-review.png`,chapter:`create`,label:`Review the Agent`,caption:`The draft converts those examples into the Agent's purpose, chat behavior, runnable actions, output formats, and Evals for your review.`,placement:`bottom-left`,narration:`The draft converts those examples into the Agent's purpose, chat behavior, runnable actions, output formats, and Evals for your review.`,focus:{x:.31,y:.04,width:.38,height:.76,zoom:1.27}},{id:`C08`,file:`C08-right-chat-question.png`,chapter:`create`,label:`Answer the planning question`,caption:`The right side panel asks how the Agent should prioritize conflicting account risks.`,placement:`top-left`,narration:`The right side panel asks how the Agent should prioritize conflicting account risks.`,focus:{x:.715,y:.19,width:.265,height:.72,zoom:1.42}},{id:`C09`,file:`C09-right-chat-plan.png`,chapter:`create`,label:`Confirm the plan`,caption:`Before creation, review the proposed name, chat endpoint, runnable actions, Evals, and output formats.`,placement:`top-left`,narration:`Before creation, review the proposed name, chat endpoint, runnable actions, Evals, and output formats.`,focus:{x:.715,y:.18,width:.265,height:.72,zoom:1.42}},{id:`C09A`,file:`C09A-edit-plan.png`,chapter:`create`,label:`Edit the plan`,caption:`If the plan misses a requirement, open Edit plan and describe the change in plain language before any Agent source is created.`,placement:`top-left`,narration:`If the plan misses a requirement, open Edit plan and describe the change in plain language before any Agent source is created.`,focus:{x:.73,y:.66,width:.24,height:.24,zoom:1.45}},{id:`C09B`,file:`C09B-revised-plan.png`,chapter:`create`,label:`Create from the revised plan`,caption:`Review the revised plan, then click Confirm plan to create the Agent and run its Evals.`,placement:`top-left`,narration:`Review the revised plan, then click Confirm plan to create the Agent and run its Evals.`,focus:{x:.72,y:.7,width:.25,height:.2,zoom:1.45}},{id:`C10`,file:`C10-candidate-evaluation.png`,chapter:`create`,label:`Review the Evals`,caption:`This is the creation result: OpenPond built the Agent and passed its behavior Evals against the Account Health examples.`,placement:`bottom-left`,narration:`This is the creation result: OpenPond built the Agent and passed its behavior Evals against the Account Health examples.`,focus:{x:.19,y:.18,width:.5,height:.22,zoom:1.36}},{id:`C11`,file:`C11-local-source-applied.png`,chapter:`create`,label:`Save the Agent`,caption:`After the Evals pass, the Agent is saved to your Profile and is ready to use.`,placement:`bottom-left`,narration:`After the Evals pass, the Agent is saved to your Profile and is ready to use.`,focus:{x:.19,y:.16,width:.5,height:.14,zoom:1.38}},{id:`C12`,file:`C12-ready-local-detail.png`,chapter:`create`,label:`Use the Agent`,caption:`The Agent page shows its purpose, chat entrypoint, and runnable account actions.`,placement:`bottom-left`,narration:`The Agent page shows its purpose, chat entrypoint, and runnable account actions.`,focus:{x:.19,y:.17,width:.5,height:.13,zoom:1.38}},{id:`C13Q`,file:`C13Q-chat-acme-prompt.png`,chapter:`use`,label:`Ask the chat endpoint`,caption:`Use opens a normal chat with the Agent attached. Type a natural-language question about Acme before sending it.`,placement:`top-left`,narration:`Use opens a normal chat with the Agent attached. Type a natural-language question about Acme before sending it.`,focus:{x:.245,y:.84,width:.39,height:.14,zoom:1.48}},{id:`C13`,file:`C13-chat-acme.png`,chapter:`use`,label:`Ask about Acme`,caption:`Acme is the at-risk example: the Agent answers in chat with renewal timing, usage decline, the disputed invoice, and the open P1 case.`,placement:`top-left`,narration:`Acme is the at-risk example: the Agent answers in chat with renewal timing, usage decline, the disputed invoice, and the open P1 case.`,focus:{x:.2,y:.08,width:.48,height:.32,zoom:1.34}},{id:`C14`,file:`C14-chat-follow-up.png`,chapter:`use`,label:`Ask a follow-up`,caption:`A follow-up keeps Acme context and assigns the first actions to Revenue Operations and Support instead of restarting the conversation.`,placement:`top-left`,narration:`A follow-up keeps Acme context and assigns the first actions to Revenue Operations and Support instead of restarting the conversation.`,focus:{x:.2,y:.08,width:.48,height:.36,zoom:1.32}},{id:`C15`,file:`C15-action-picker.png`,chapter:`use`,label:`Choose a direct action`,caption:`The action picker offers chat plus each runnable account action, so you can choose conversation or a focused task.`,placement:`top-left`,narration:`The action picker offers chat plus each runnable account action, so you can choose conversation or a focused task.`,focus:{x:.245,y:.84,width:.39,height:.14,zoom:1.48}},{id:`C16`,file:`C16-northstar-summary.png`,chapter:`use`,label:`Summarize Northstar`,caption:`Northstar is the healthy expansion example from the source chats. Its direct summary identifies rising usage and the request for twenty-five more seats.`,placement:`top-left`,narration:`Northstar is the healthy expansion example from the source chats. Its direct summary identifies rising usage and the request for twenty-five more seats.`,focus:{x:.2,y:.37,width:.48,height:.2,zoom:1.38}},{id:`C17`,file:`C17-acme-triage.png`,chapter:`use`,label:`Triage Acme`,caption:`Running renewal triage for Acme returns high risk, cites the billing and support blockers, and orders the next steps.`,placement:`top-left`,narration:`Running renewal triage for Acme returns high risk, cites the billing and support blockers, and orders the next steps.`,focus:{x:.2,y:.57,width:.48,height:.15,zoom:1.4}},{id:`C18`,file:`C18-weekly-review-artifacts.png`,chapter:`use`,label:`Build the weekly review`,caption:`The weekly review action combines the portfolio and returns visible Markdown, CSV, and JSON artifacts for downstream use.`,placement:`top-left`,narration:`The weekly review action combines the portfolio and returns visible Markdown, CSV, and JSON artifacts for downstream use.`,focus:{x:.2,y:.68,width:.48,height:.19,zoom:1.36}},{id:`C19`,file:`C19-after-restart.png`,chapter:`use`,label:`Verify persistence`,caption:`After restarting OpenPond, the same Agent, chat history, and actions remain available.`,placement:`bottom-left`,narration:`After restarting OpenPond, the same Agent, chat history, and actions remain available.`,focus:{x:.19,y:.16,width:.5,height:.15,zoom:1.38}},{id:`I00`,file:`I00-current-priority-gap.png`,chapter:`improve`,label:`Identify the behavior gap`,caption:`The current Agent finds the right facts, but buries the priority after the account summary. Improve will make the billing and P1 decision lead every high-risk result.`,placement:`top-left`,narration:`The current Agent finds the right facts, but buries the priority after the account summary. Improve will make the billing and P1 decision lead every high-risk result.`,focus:{x:.38,y:.06,width:.42,height:.18,zoom:1.4}},{id:`I01`,file:`I01-improve-source-choice.png`,chapter:`improve`,label:`Start Improve`,caption:`Open Improve agent on the existing Agent, then choose whether to describe the correction directly or include a chat that demonstrates it.`,placement:`bottom-left`,narration:`Open Improve agent on the existing Agent, then choose whether to describe the correction directly or include a chat that demonstrates it.`,focus:{x:.31,y:.34,width:.38,height:.31,zoom:1.42}},{id:`I02`,file:`I02-improve-from-chats.png`,chapter:`improve`,label:`Add the correction chat`,caption:`Choose From chats, ask every high-risk response to lead with the billing and P1 decision, and attach the correction conversation that demonstrates it.`,placement:`top-left`,narration:`Choose From chats, ask every high-risk response to lead with the billing and P1 decision, and attach the correction conversation that demonstrates it.`,focus:{x:.31,y:.2,width:.38,height:.6,zoom:1.32}},{id:`I03`,file:`I03-improve-review.png`,chapter:`improve`,label:`Review the improvement`,caption:`Review the new lead-with-priority behavior, the existing capabilities that must stay intact, and the Evals OpenPond will rerun.`,placement:`bottom-left`,narration:`Review the new lead-with-priority behavior, the existing capabilities that must stay intact, and the Evals OpenPond will rerun.`,focus:{x:.31,y:.04,width:.38,height:.76,zoom:1.27}},{id:`I04`,file:`I04-improve-right-chat-plan.png`,chapter:`improve`,label:`Confirm the Improve plan`,caption:`Review the planned change and confirm that it preserves citations and every existing action.`,placement:`top-left`,narration:`Review the planned change and confirm that it preserves citations and every existing action.`,focus:{x:.715,y:.18,width:.265,height:.72,zoom:1.42}},{id:`I05`,file:`I05-improve-comparison.png`,chapter:`improve`,label:`Compare the results`,caption:`The same locked Evals make the decision clear: the current Agent misses the new lead sentence, while the updated Agent passes every original and new Eval.`,placement:`bottom-left`,narration:`The same locked Evals make the decision clear: the current Agent misses the new lead sentence, while the updated Agent passes every original and new Eval.`,focus:{x:.745,y:.8,width:.22,height:.13,zoom:1.5}},{id:`I06`,file:`I06-improved-release.png`,chapter:`improve`,label:`Save the improvement`,caption:`Apply the update only after that comparison. The existing Agent updates in place, with the successful Evals recorded.`,placement:`bottom-left`,narration:`Apply the update only after that comparison. The existing Agent updates in place, with the successful Evals recorded.`,focus:{x:.71,y:.16,width:.28,height:.22,zoom:1.45}},{id:`I07`,file:`I07-improved-chat.png`,chapter:`improve`,label:`Verify improved chat`,caption:`The improved chat now places disputed billing and the open P1 case ahead of adoption decline while preserving source citations.`,placement:`top-left`,narration:`The improved chat now places disputed billing and the open P1 case ahead of adoption decline while preserving source citations.`,focus:{x:.2,y:.08,width:.48,height:.16,zoom:1.4}},{id:`I08`,file:`I08-improved-triage.png`,chapter:`improve`,label:`Verify improved triage`,caption:`The direct triage action repeats the billing-first result, proving the change works outside chat without breaking the existing workflow.`,placement:`top-left`,narration:`The direct triage action repeats the billing-first result, proving the change works outside chat without breaking the existing workflow.`,focus:{x:.2,y:.27,width:.48,height:.16,zoom:1.4}},{id:`I09`,file:`I09-profile-commit-dialog.png`,chapter:`improve`,label:`Commit the Profile source`,caption:`Commit the final Agent source with a clear Git message so the exact Profile version remains reviewable and shareable.`,placement:`bottom-left`,narration:`Commit the final Agent source with a clear Git message so the exact Profile version remains reviewable and shareable.`,focus:{x:.37,y:.36,width:.26,height:.29,zoom:1.45}},{id:`I10`,file:`I10-profile-sync-dialog.png`,chapter:`improve`,label:`Review the hosted sync`,caption:`Open Sync to review the committed Profile changes. Confirm sync publishes this version so teammates can use the Agent in chat and hosted sandboxes can attach the same source.`,placement:`bottom-left`,narration:`Open Sync to review the committed Profile changes. Confirm sync publishes this version so teammates can use the Agent in chat and hosted sandboxes can attach the same source.`,focus:{x:.5,y:.61,width:.11,height:.07,zoom:1.55}}],frameMinimumDuration:5.2,focusStyle:{borderColor:`#22d3ee`,borderWidth:5,dimOpacity:.32,zoomDelaySeconds:.8,zoomDurationSeconds:1.2}},se=w(`how-to-make-an-agent`),O=D.chapters,ce={create:`1:24`,use:`1:05`,improve:`1:10`},k=se.title,le=D.tutorial.title,A=`4:33`,j={captionsUrl:l,chapterIds:O.map(e=>e.id),description:`Create, use, and improve an Account Health Agent in one continuous walkthrough.`,duration:A,eyebrow:`Play all`,id:`make-agent-tutorial`,lessonNumber:null,posterUrl:o,title:le,videoId:`play-all`,videoUrl:ae},M=O.map((e,t)=>({captionsUrl:u(e.id),chapterIds:[e.id],description:e.subtitle,duration:ce[e.id],eyebrow:`Lesson ${t+1}`,id:`make-agent-tutorial-${e.id}`,lessonNumber:t+1,posterUrl:n(e.id),title:e.title,videoId:e.id,videoUrl:oe(e.id)})),ue=[j,...M];function N(e){return ue.find(t=>t.videoId===e)??j}function de(e){let t=M.findIndex(t=>t.videoId===e);return t<0?null:M[t+1]?.videoId??null}var fe=[2,1,0];function pe({activeVideoId:e=`play-all`,autoplay:t=!0,onClose:n,onOpen:r,onSelectVideo:i,open:a=!1,playRequestId:o=0}={}){let s=(0,v.useRef)(null),c=N(e);(0,v.useEffect)(()=>{if(!a)return;let e=s.current;e&&(e.load(),o>0&&e.play().catch(()=>void 0))},[c.id,a,o]);function l(){if(!t||!i)return;let n=de(e);n&&i(n)}return(0,y.jsxs)(`section`,{className:`get-started-series`,"aria-label":k,children:[(0,y.jsxs)(`article`,{className:`get-started-playlist-card`,"aria-labelledby":`make-agent-series-title`,children:[(0,y.jsx)(`button`,{"aria-haspopup":`dialog`,"aria-label":`Open ${k} playlist`,className:`get-started-playlist-open`,onClick:r,type:`button`}),(0,y.jsxs)(`div`,{className:`get-started-playlist-stack`,"aria-hidden":`true`,children:[fe.map((e,t)=>{let n=M[e];return(0,y.jsx)(`div`,{className:`get-started-playlist-poster layer-${t+1}`,children:(0,y.jsx)(`img`,{alt:``,decoding:`async`,src:n.posterUrl})},n.id)}),(0,y.jsx)(`span`,{className:`get-started-course-play-icon`,children:(0,y.jsx)(m,{fill:`currentColor`,size:19})}),(0,y.jsxs)(`span`,{className:`get-started-playlist-count`,children:[M.length,` lessons`]})]}),(0,y.jsxs)(`div`,{className:`get-started-playlist-copy`,children:[(0,y.jsx)(`h1`,{id:`make-agent-series-title`,children:k}),(0,y.jsxs)(`div`,{className:`get-started-course-meta`,children:[(0,y.jsx)(`span`,{children:`Walkthrough playlist`}),(0,y.jsx)(`span`,{"aria-hidden":`true`,children:`·`}),(0,y.jsx)(`span`,{children:A})]}),(0,y.jsx)(`p`,{children:`Create, use, and improve an Account Health Agent, or play the full walkthrough.`})]})]}),a&&n&&i?(0,y.jsx)(me,{activeVideoId:e,autoplay:t,contained:!0,inertExclusionSelector:`.get-started-learning-panel`,onClose:n,onEnded:l,onSelectVideo:i,videoRef:s}):null]})}function me({activeVideoId:e=`play-all`,autoplay:t=!0,contained:n=!1,inertExclusionSelector:r,onClose:i,onEnded:a,onSelectVideo:o=()=>void 0,videoRef:s}){let c=N(e),l=M.findIndex(t=>t.videoId===e),u=l>=0?M[l+1]?.videoId:void 0,d=l>0?M[l-1]?.videoId:void 0;return(0,y.jsx)(b,{autoAdvance:t&&l>=0,contained:n,inertExclusionSelector:r,navigation:l>=0?{currentIndex:l,onNext:u?()=>o(u):void 0,onPrevious:d?()=>o(d):void 0,total:M.length}:void 0,onClose:i,onEnded:a?()=>a():void 0,video:c,videoRef:s})}var P=w(`post-training-from-first-principles`),F=P.title,he=P.status;function I(e,t,n,i,a,o){let s=`courses/post-training/${t}`,c=`post-training-${t}`;return{captionsUrl:r(`${s}.vtt`),description:o,duration:a,eyebrow:i,id:c,lessonNumber:e,posterUrl:r(`${s}-poster.webp`),slug:t,title:n,videoUrl:T(c)}}var L=[I(1,`01-how-post-training-works`,`How post-training works`,`Start here`,`1:05`,`The choose, judge, and update loop behind every method in this series.`),I(2,`02-definitions`,`Definitions`,`Reference`,`6:14`,`Policy notation, softmax, rollouts, advantages, gradients, GRPO, and the acronyms used throughout the series.`),I(3,`03-on-policy-off-policy`,`On-policy and off-policy data`,`Data source`,`1:06`,`Why learner rollouts and teacher or stored data support different updates.`),I(4,`04-rewards-credit-assignment`,`Rewards and credit assignment`,`RL foundation`,`3:00`,`Follow a code-repair trajectory from actions and observations to advantage.`),I(5,`05-verifiable-rewards-rlvr`,`Verifiable rewards`,`RLVR`,`2:53`,`See how tests create scalable rewards—and how a model can exploit the checker.`),I(6,`06-ppo-grpo`,`PPO and GRPO`,`Policy updates`,`2:54`,`Compare PPO's learned critic with GRPO's sibling-response baseline.`),I(7,`07-distillation`,`Distillation`,`Teacher targets`,`2:42`,`Transfer a teacher's token distribution instead of copying one final answer.`),I(8,`08-opsd-sdft-sdpo`,`OPSD, SDFT, and SDPO`,`Teacher evidence`,`2:43`,`Compare trusted solutions, demonstrations, and failure feedback at one prefix.`),I(9,`09-credible-experiments`,`Credible experiments`,`Research design`,`3:32`,`Build versioned datasets, fair baselines, and claims that survive scrutiny.`),I(10,`10-technical-appendix`,`Technical appendix`,`Advanced details`,`3:12`,`Inspect GRPO normalization, compressed teacher logits, reported method results, and sample routing.`)],ge=`29 min`,R=P.fullVideoId;if(!R)throw Error(`Post-training playlist is missing its full video`);var z={captionsUrl:r(`courses/post-training/full-course.vtt`),description:`All ten lessons in one continuous video for watching, sharing, or uploading.`,duration:`29:20`,eyebrow:`Full course`,id:R,posterUrl:r(`courses/post-training/full-course-poster.webp`),title:F,videoUrl:T(R)};function B(e){let t=e+1;return t<L.length?t:null}var V=`Subject to change, lesson work in progress`;function _e(){let e=he===`draft`?`Draft`:`Published`;return(0,y.jsx)(`span`,{"aria-label":`${e}: ${V}`,className:`get-started-playlist-status app-tooltip`,"data-tooltip":V,tabIndex:0,children:e})}var H=`openpond.post-training-progress.v1`,U=Object.freeze({}),ve=1e3,W=new Set,G=null,K=null,q=!1;function J(e){return typeof e==`number`&&Number.isFinite(e)?e:null}function ye(e){if(!e||typeof e!=`object`||Array.isArray(e))return U;let t={};for(let[n,r]of Object.entries(e)){if(!n||!r||typeof r!=`object`||Array.isArray(r))continue;let e=r,i=J(e.duration),a=J(e.currentTime),o=J(e.updatedAt);if(i===null||i<=0||a===null)continue;let s=e.completed===!0;t[n]={completed:s,currentTime:s?i:Math.min(i,Math.max(0,a)),duration:i,updatedAt:o===null?0:Math.max(0,o)}}return Object.keys(t).length>0?t:U}function be(e){if(!e)return U;try{return ye(JSON.parse(e))}catch{return U}}function Y(){if(typeof window>`u`)return U;try{return be(f.getItem(H))}catch{return U}}function X(){if(typeof window<`u`&&K!==null&&window.clearTimeout(K),K=null,typeof window<`u`&&G!==null)try{f.setItem(H,JSON.stringify(G))}catch{}}function xe(){typeof window<`u`&&K===null&&(K=window.setTimeout(X,ve))}function Se(){typeof window>`u`||q||(q=!0,window.addEventListener(`pagehide`,X),d(()=>{G=Y(),W.forEach(e=>e())}))}function Z(){return G===null&&(G=Y()),Se(),G}function Q({completed:e=!1,currentTime:t,duration:n,lessonId:r}){if(!r||!Number.isFinite(n)||n<=0||!Number.isFinite(t))return;let i=Z(),a=i[r],o=!!(a?.completed||e),s=o?n:Math.min(n,Math.max(0,t));a&&a.completed===o&&Math.abs(a.currentTime-s)<.25&&Math.abs(a.duration-n)<.25||(G={...i,[r]:{completed:o,currentTime:s,duration:n,updatedAt:Date.now()}},xe(),W.forEach(e=>e()))}function Ce(e){return!e||e.completed||e.currentTime<1?0:e.currentTime<e.duration-2?e.currentTime:0}var $=F,we=[2,1,0];function Te({activeLessonIndex:e,fullCourseSelected:t=!1,autoplay:n=!0,open:r,onClose:i,onOpen:a,onSelectLesson:o,playRequestId:s=0}){let c=(0,v.useRef)(null),l=(0,v.useRef)(null),u=L[e]??L[0],d=t?z:u;(0,v.useEffect)(()=>{if(!r)return;let e=c.current;if(!e)return;let t=!1;l.current=null,e.load();let n=()=>{if(t)return;let n=Ce(Z()[d.id]);n>0&&(e.currentTime=n),s>0&&e.play().catch(()=>void 0)};return e.readyState>=HTMLMediaElement.HAVE_METADATA?n():e.addEventListener(`loadedmetadata`,n,{once:!0}),()=>{t=!0,e.removeEventListener(`loadedmetadata`,n),Number.isFinite(e.duration)&&e.duration>0&&e.currentTime>0&&Q({completed:e.ended,currentTime:e.currentTime,duration:e.duration,lessonId:d.id})}},[d.id,r,s]);function f(e,t=!1){!Number.isFinite(e.duration)||e.duration<=0||Q({completed:t,currentTime:t?e.duration:e.currentTime,duration:e.duration,lessonId:d.id})}function p(e){if(!Number.isFinite(e.duration)||e.duration<=0)return;let t=Math.min(99,Math.floor(e.currentTime/e.duration*100)),n=l.current;(n?.lessonId!==d.id||n.percent!==t)&&(l.current={lessonId:d.id,percent:t},f(e))}function h(e){f(e,!0),n&&!t&&g()}function g(){let t=B(e);t!==null&&o(t)}return(0,y.jsxs)(`section`,{className:`get-started-series`,"aria-label":$,children:[(0,y.jsxs)(`article`,{className:`get-started-playlist-card`,"aria-labelledby":`post-training-series-title`,children:[(0,y.jsx)(`button`,{"aria-haspopup":`dialog`,"aria-label":`Open ${$} playlist`,className:`get-started-playlist-open`,onClick:a,type:`button`}),(0,y.jsxs)(`div`,{className:`get-started-playlist-stack`,"aria-hidden":`true`,children:[we.map((e,t)=>{let n=L[e];return(0,y.jsx)(`div`,{className:`get-started-playlist-poster layer-${t+1}`,children:(0,y.jsx)(`img`,{alt:``,decoding:`async`,src:n.posterUrl})},n.id)}),(0,y.jsx)(`span`,{className:`get-started-course-play-icon`,children:(0,y.jsx)(m,{fill:`currentColor`,size:19})}),(0,y.jsxs)(`span`,{className:`get-started-playlist-count`,children:[L.length,` lessons`]})]}),(0,y.jsxs)(`div`,{className:`get-started-playlist-copy`,children:[(0,y.jsxs)(`div`,{className:`get-started-playlist-title`,children:[(0,y.jsx)(`h1`,{id:`post-training-series-title`,children:$}),(0,y.jsx)(_e,{})]}),(0,y.jsxs)(`div`,{className:`get-started-course-meta`,children:[(0,y.jsx)(`span`,{children:`Learning series`}),(0,y.jsx)(`span`,{"aria-hidden":`true`,children:`·`}),(0,y.jsx)(`span`,{children:ge})]}),(0,y.jsx)(`p`,{children:`Rewards, GRPO, RLVR, distillation, experiments, and a technical appendix.`})]})]}),r?(0,y.jsx)(Ee,{activeLessonIndex:e,autoplay:n,fullCourseSelected:t,onClose:i,onEnded:h,onPause:f,onSelectLesson:o,onTimeUpdate:p,videoRef:c}):null]})}function Ee({activeLessonIndex:e,autoplay:t,fullCourseSelected:n,onClose:r,onEnded:i,onPause:a,onSelectLesson:o,onTimeUpdate:s,videoRef:c}){let l=L[e]??L[0],u=B(e),d=n?z:l;return(0,y.jsx)(b,{autoAdvance:t&&!n,contained:!0,inertExclusionSelector:`.get-started-learning-panel`,navigation:n?void 0:{currentIndex:e,onNext:u===null?void 0:()=>o(u),onPrevious:e>0?()=>o(e-1):void 0,total:L.length},onClose:r,onEnded:i,onPause:a,onTimeUpdate:s,video:d,videoRef:c})}var De={captionsUrl:t,description:`See how Profile Agents combine chat, direct actions, shared runtime surfaces, and Evals.`,duration:`1:16`,eyebrow:`Agent overview`,id:`openpond-agent-overview`,posterUrl:c,title:`What is an OpenPond Agent?`,videoUrl:E};function Oe(e={}){let[t,n]=(0,v.useState)(null),[r,i]=(0,v.useState)(null),a=e.makeAgentTutorial===void 0?t:e.makeAgentTutorial,o=e.postTrainingCourse===void 0?r:e.postTrainingCourse,s=!!(o||a);function c(){e.onOpenMakeAgentTutorial?e.onOpenMakeAgentTutorial():(i(null),n({autoplay:!0,playRequestId:0,videoId:`create`}))}function l(){e.onCloseMakeAgentTutorial?e.onCloseMakeAgentTutorial():n(null)}function u(t){e.onSelectMakeAgentTutorialVideo?e.onSelectMakeAgentTutorialVideo(t):n(e=>e&&{...e,playRequestId:e.playRequestId+1,videoId:t})}function d(){e.onOpenPostTrainingCourse?e.onOpenPostTrainingCourse():(n(null),i({autoplay:!0,fullCourseSelected:!1,lessonIndex:0,playRequestId:0}))}function f(){e.onClosePostTrainingCourse?e.onClosePostTrainingCourse():i(null)}function p(t){e.onSelectPostTrainingLesson?e.onSelectPostTrainingLesson(t):i(e=>e&&{...e,fullCourseSelected:!1,lessonIndex:t,playRequestId:e.playRequestId+1})}return(0,y.jsx)(`section`,{className:`get-started-view ${s?`course-player-open`:``}`,"aria-label":`Walkthroughs`,children:(0,y.jsxs)(`div`,{className:`get-started-shell`,children:[(0,y.jsxs)(`section`,{className:`get-started-start-here`,"aria-labelledby":`get-started-start-here-title`,children:[(0,y.jsx)(`header`,{className:`get-started-section-heading`,children:(0,y.jsx)(`h2`,{id:`get-started-start-here-title`,children:`Start here`})}),(0,y.jsx)(`div`,{className:`get-started-learning-grid`,children:(0,y.jsx)(te,{titleElement:`h1`,video:De})})]}),(0,y.jsxs)(`section`,{className:`get-started-walkthroughs`,"aria-labelledby":`get-started-walkthroughs-title`,children:[(0,y.jsx)(`header`,{className:`get-started-section-heading`,children:(0,y.jsx)(`h2`,{id:`get-started-walkthroughs-title`,children:`Walkthroughs`})}),(0,y.jsx)(`div`,{className:`get-started-learning-grid`,children:(0,y.jsx)(pe,{activeVideoId:a?.videoId??`create`,autoplay:a?.autoplay??!0,onClose:l,onOpen:c,onSelectVideo:u,open:!!a,playRequestId:a?.playRequestId??0})})]}),(0,y.jsxs)(`section`,{className:`get-started-learn`,"aria-labelledby":`get-started-learn-title`,children:[(0,y.jsx)(`header`,{className:`get-started-section-heading`,children:(0,y.jsx)(`h2`,{id:`get-started-learn-title`,children:`Learn deeper`})}),(0,y.jsx)(`div`,{className:`get-started-learning-grid`,children:(0,y.jsx)(Te,{activeLessonIndex:o?.lessonIndex??0,autoplay:o?.autoplay??!0,fullCourseSelected:o?.fullCourseSelected??!1,open:!!o,onClose:f,onOpen:d,onSelectLesson:p,playRequestId:o?.playRequestId??0})})]})]})})}export{Oe as GetStartedView};
|
|
1
|
+
import{i as e}from"./rolldown-runtime-Dd_uD5pT.js";import{a as t,d as n,f as r,g as i,h as a,i as o,m as s,o as c,r as l,u}from"./index-DG0kf1wK.js";import{a as d,n as f}from"./client-choice-storage-D_6dVX8O.js";import"./icons-nr5d1kC-.js";import{V as p}from"./training-model-data-CilS0W2N.js";import{t as m}from"./play-DF5h_-8T.js";import{t as h}from"./x-CQ0pGF6Q.js";import{t as g}from"./AppDialog-wmL4BlOJ.js";import{Cn as _}from"./App-CqqK4NLa.js";var v=e(i(),1),ee=a(),y=s();function te({badge:e,onPlay:t,titleElement:n=`h3`,video:r}){let[i,a]=(0,v.useState)(!1),o=(0,v.useRef)(null),s=n,c=`${r.id}-title`;function l(){if(t){t();return}(0,ee.flushSync)(()=>a(!0));let e=o.current;e&&(e.load(),e.play().catch(()=>void 0))}return(0,y.jsxs)(y.Fragment,{children:[(0,y.jsxs)(`article`,{className:`get-started-course-card`,"aria-labelledby":c,children:[(0,y.jsx)(`button`,{"aria-haspopup":`dialog`,"aria-label":`Play ${r.title}`,className:`get-started-course-open`,onClick:l,type:`button`}),(0,y.jsxs)(`div`,{className:`get-started-course-media`,children:[(0,y.jsx)(`img`,{alt:``,className:`get-started-course-poster`,decoding:`async`,src:r.posterUrl}),(0,y.jsx)(`span`,{className:`get-started-course-play-icon`,"aria-hidden":`true`,children:(0,y.jsx)(m,{fill:`currentColor`,size:19})}),e?(0,y.jsx)(`span`,{className:`get-started-course-badge`,"aria-hidden":`true`,children:e}):null]}),(0,y.jsxs)(`div`,{className:`get-started-course-copy`,children:[(0,y.jsx)(s,{id:c,children:r.title}),(0,y.jsxs)(`div`,{className:`get-started-course-meta`,"aria-label":`${r.title} details`,children:[(0,y.jsx)(`span`,{children:r.eyebrow}),(0,y.jsx)(`span`,{"aria-hidden":`true`,children:`·`}),(0,y.jsx)(`span`,{children:r.duration})]}),r.description?(0,y.jsx)(`p`,{children:r.description}):null]})]}),i&&!t?(0,y.jsx)(b,{onClose:()=>a(!1),video:r,videoRef:o}):null]})}function b({autoAdvance:e=!1,contained:t=!1,inertExclusionSelector:n,navigation:r,onEnded:i,onClose:a,onPause:o,onTimeUpdate:s,video:c,videoRef:l}){return(0,y.jsxs)(g,{ariaLabel:`${c.title} player`,backdropClassName:`get-started-course-player-backdrop`,className:`get-started-course-player`,contained:t,inertExclusionSelector:n,onClose:a,children:[(0,y.jsxs)(`header`,{className:`get-started-course-player-header`,children:[(0,y.jsxs)(`div`,{className:`get-started-course-player-copy`,children:[(0,y.jsx)(`strong`,{children:c.title}),(0,y.jsxs)(`span`,{children:[r?`Lesson ${r.currentIndex+1} of ${r.total}`:c.eyebrow,` · `,c.duration]})]}),(0,y.jsxs)(`div`,{className:`get-started-course-player-actions`,children:[r?(0,y.jsxs)(y.Fragment,{children:[(0,y.jsx)(`button`,{"aria-label":`Previous lesson`,disabled:!r.onPrevious,onClick:r.onPrevious,title:`Previous lesson`,type:`button`,children:(0,y.jsx)(_,{size:17})}),(0,y.jsx)(`button`,{"aria-label":`Next lesson`,disabled:!r.onNext,onClick:r.onNext,title:`Next lesson`,type:`button`,children:(0,y.jsx)(p,{size:17})})]}):null,(0,y.jsx)(`button`,{"aria-label":`Close video player`,"data-autofocus":!0,onClick:a,title:`Close`,type:`button`,children:(0,y.jsx)(h,{size:18})})]})]}),(0,y.jsx)(`div`,{className:`get-started-course-player-body`,children:(0,y.jsx)(`div`,{className:`get-started-course-player-media`,children:(0,y.jsx)(`div`,{className:`get-started-course-player-stage`,children:(0,y.jsx)(`video`,{"aria-label":`${c.title} video`,className:`get-started-course-player-video`,controls:!0,"data-auto-advance":e?`true`:void 0,onEnded:e=>i?.(e.currentTarget),onPause:e=>o?.(e.currentTarget),onTimeUpdate:e=>s?.(e.currentTarget),playsInline:!0,poster:c.posterUrl,preload:`metadata`,ref:l,src:c.videoUrl,children:c.captionsUrl?(0,y.jsx)(`track`,{kind:`captions`,label:`English`,src:c.captionsUrl,srcLang:`en`}):null},c.id)})})})]})}var x={schemaVersion:`openpond.publicVideoManifest.v1`,playlists:[{id:`post-training-from-first-principles`,fullVideoId:`post-training-full-course`,status:`draft`,title:`Post-training from first principles`,videoIds:[`post-training-01-how-post-training-works`,`post-training-02-definitions`,`post-training-03-on-policy-off-policy`,`post-training-04-rewards-credit-assignment`,`post-training-05-verifiable-rewards-rlvr`,`post-training-06-ppo-grpo`,`post-training-07-distillation`,`post-training-08-opsd-sdft-sdpo`,`post-training-09-credible-experiments`,`post-training-10-technical-appendix`]},{id:`how-to-make-an-agent`,status:`published`,title:`Agents`,playAllVideoId:`make-agent-tutorial`,videoIds:[`make-agent-tutorial-create`,`make-agent-tutorial-use`,`make-agent-tutorial-improve`]}],videos:[{id:`post-training-01-how-post-training-works`,localPath:`courses/post-training/01-how-post-training-works.mp4`,objectKey:`media/videos/aeb54dfb42eb940672df6e41bae075ffa5e45e1609e173a91e485c808b61fd4a.mp4`,sha256:`aeb54dfb42eb940672df6e41bae075ffa5e45e1609e173a91e485c808b61fd4a`,sizeBytes:2114638,durationSeconds:64.967},{id:`post-training-02-definitions`,localPath:`courses/post-training/02-definitions.mp4`,objectKey:`media/videos/c57d021989cdf058c683b9d017eb91bd23075e6bd00d0cc055e1285b3ea119fc.mp4`,sha256:`c57d021989cdf058c683b9d017eb91bd23075e6bd00d0cc055e1285b3ea119fc`,sizeBytes:11956956,durationSeconds:374.367},{id:`post-training-03-on-policy-off-policy`,localPath:`courses/post-training/03-on-policy-off-policy.mp4`,objectKey:`media/videos/a807bd7d704f8603addc875623a3cfcc938e60e0170d555d47569394a1c31762.mp4`,sha256:`a807bd7d704f8603addc875623a3cfcc938e60e0170d555d47569394a1c31762`,sizeBytes:2291518,durationSeconds:66.367},{id:`post-training-04-rewards-credit-assignment`,localPath:`courses/post-training/04-rewards-credit-assignment.mp4`,objectKey:`media/videos/685f7ecff7fcea262dd2cf60568079633816e9116efd80c069d0e20a4959a87f.mp4`,sha256:`685f7ecff7fcea262dd2cf60568079633816e9116efd80c069d0e20a4959a87f`,sizeBytes:5677418,durationSeconds:179.834},{id:`post-training-05-verifiable-rewards-rlvr`,localPath:`courses/post-training/05-verifiable-rewards-rlvr.mp4`,objectKey:`media/videos/0633584b2036843edd1ff9c63f0858db4272ddf55b10b160ec2ef6f7650c7d3a.mp4`,sha256:`0633584b2036843edd1ff9c63f0858db4272ddf55b10b160ec2ef6f7650c7d3a`,sizeBytes:5666892,durationSeconds:172.534},{id:`post-training-06-ppo-grpo`,localPath:`courses/post-training/06-ppo-grpo.mp4`,objectKey:`media/videos/66760fec7508c413844adb06c3f3920c5f7e3a874b18dc244ba090c55f452ff3.mp4`,sha256:`66760fec7508c413844adb06c3f3920c5f7e3a874b18dc244ba090c55f452ff3`,sizeBytes:5519257,durationSeconds:173.6},{id:`post-training-07-distillation`,localPath:`courses/post-training/07-distillation.mp4`,objectKey:`media/videos/3590f94325c1986f2025b42d182f04957e9eff6d5c06b1effc28dc369651c466.mp4`,sha256:`3590f94325c1986f2025b42d182f04957e9eff6d5c06b1effc28dc369651c466`,sizeBytes:4687640,durationSeconds:161.667},{id:`post-training-08-opsd-sdft-sdpo`,localPath:`courses/post-training/08-opsd-sdft-sdpo.mp4`,objectKey:`media/videos/3c45d8c1df0a24132ec425762dc6a4274b1e5cac6dfd220a2994f8754f431031.mp4`,sha256:`3c45d8c1df0a24132ec425762dc6a4274b1e5cac6dfd220a2994f8754f431031`,sizeBytes:5439835,durationSeconds:163.134},{id:`post-training-09-credible-experiments`,localPath:`courses/post-training/09-credible-experiments.mp4`,objectKey:`media/videos/fc701a8ba4b42de53bcaec3dcf191e6ec66f1dc0c48480f0aff01c3849aff023.mp4`,sha256:`fc701a8ba4b42de53bcaec3dcf191e6ec66f1dc0c48480f0aff01c3849aff023`,sizeBytes:6909405,durationSeconds:211.934},{id:`post-training-10-technical-appendix`,localPath:`courses/post-training/10-technical-appendix.mp4`,objectKey:`media/videos/17e6b5ef161fcdc97678e5b63650bffdb4b4b0d510ba75725a2af8a5db0d7e21.mp4`,sha256:`17e6b5ef161fcdc97678e5b63650bffdb4b4b0d510ba75725a2af8a5db0d7e21`,sizeBytes:5481950,durationSeconds:191.767},{id:`post-training-full-course`,localPath:`courses/post-training/full-course.mp4`,objectKey:`media/videos/d3df6a3b2ffe6c696b9dc0774ceaec19a2b8a92b170476cacb9df8dbdb2a526f.mp4`,sha256:`d3df6a3b2ffe6c696b9dc0774ceaec19a2b8a92b170476cacb9df8dbdb2a526f`,sizeBytes:55740426,durationSeconds:1760.192},{id:`openpond-agent-overview`,localPath:`tutorials/what-is-an-openpond-agent.mp4`,objectKey:`media/videos/421160f56d82abd6515df0d5ccf144591749e0ab1d58d630805c4807913812c7.mp4`,sha256:`421160f56d82abd6515df0d5ccf144591749e0ab1d58d630805c4807913812c7`,sizeBytes:5259848,durationSeconds:77.467},{id:`make-agent-tutorial`,localPath:`tutorials/how-to-make-an-agent.mp4`,objectKey:`media/videos/252d2f27076c904d85c9854c2f4c494fe9e92b3cea7d2c58ffbaa0323c17f255.mp4`,sha256:`252d2f27076c904d85c9854c2f4c494fe9e92b3cea7d2c58ffbaa0323c17f255`,sizeBytes:17339101,durationSeconds:273.067},{id:`make-agent-tutorial-create`,localPath:`tutorials/how-to-make-an-agent-create.mp4`,objectKey:`media/videos/322c999225d4759c34334eee22edee25a737fb06c5c6d66ee1f84485bb586c44.mp4`,sha256:`322c999225d4759c34334eee22edee25a737fb06c5c6d66ee1f84485bb586c44`,sizeBytes:6050301,durationSeconds:100.4},{id:`make-agent-tutorial-use`,localPath:`tutorials/how-to-make-an-agent-use.mp4`,objectKey:`media/videos/6e28bb710f90de8968fa18f996973b869e6748797739dd93cce49d8fbba564c1.mp4`,sha256:`6e28bb710f90de8968fa18f996973b869e6748797739dd93cce49d8fbba564c1`,sizeBytes:5084394,durationSeconds:75.1},{id:`make-agent-tutorial-improve`,localPath:`tutorials/how-to-make-an-agent-improve.mp4`,objectKey:`media/videos/fe8b62bf6ed5f5b933b0023dfdd9a06e69b5b352d4c702b671ec7677b395d58d.mp4`,sha256:`fe8b62bf6ed5f5b933b0023dfdd9a06e69b5b352d4c702b671ec7677b395d58d`,sizeBytes:6255324,durationSeconds:108.634}]},S=`https://media.openpond.ai`,C=x,ne=new Map(C.playlists.map(e=>[e.id,e])),re=new Map(C.videos.map(e=>[e.id,e]));function w(e){let t=ne.get(e);if(!t)throw Error(`Public video manifest is missing playlist ${e}`);return t}function ie(e,t){return t?`${S}/${e.objectKey}`:r(e.localPath)}function T(e){let t=re.get(e);if(!t)throw Error(`Public video manifest is missing ${e}`);return ie(t,!0)}var ae=T(`make-agent-tutorial`),E=T(`openpond-agent-overview`);function oe(e){return T(`make-agent-tutorial-${e}`)}var D={schemaVersion:`openpond.tutorialFrames.v2`,tutorial:{title:`How to make an agent`,subtitle:`Create, run, improve, and verify an Account Health Agent.`,outroTitle:`Agent shared from the hosted Profile`,outroSubtitle:`Available to teammates and hosted sandboxes. · Synthetic tutorial data · AI-generated narration`,narration:{model:`gpt-4o-mini-tts-2025-12-15`,voice:`cedar`,speed:1.12,responseFormat:`wav`,instructions:`Warm, clear product tutorial narration. Speak at a calm conversational pace with practical emphasis on user choices, evidence, approvals, and results. Pronounce OpenPond as open pond, P1 as P one, CSV as C S V, JSON as jay son, and Taskset as task set. Finish each sentence cleanly. Avoid hype, sales cadence, dramatic delivery, or imitation of any real person.`,leadInSeconds:.55,tailSeconds:.7,audioTitle:`AI-generated narration`,audioCredit:`OpenAI Speech · Cedar voice`}},chapters:[{id:`create`,label:`Create`,title:`Create an Agent`,subtitle:`Turn a plain-language purpose into a working Account Health Agent.`,outroTitle:`Account Health Agent created`,outroSubtitle:`The agent is ready to use. · AI-generated narration`,cardDuration:1.5},{id:`use`,label:`Use`,title:`Use the Agent`,subtitle:`Chat with the Account Health Agent and run its actions with approval.`,outroTitle:`First agent run complete`,outroSubtitle:`The result and supporting evidence are ready to review. · AI-generated narration`,cardDuration:1.5},{id:`improve`,label:`Improve`,title:`Improve the Agent`,subtitle:`Use real run evidence and Evals to make the Account Health Agent better.`,outroTitle:`Account Health Agent improved`,outroSubtitle:`The updated agent passed its Evals. · AI-generated narration`,cardDuration:1.5}],transitionDuration:.33,frames:[{id:`C01`,file:`C01-account-agent-lab-create-menu.png`,chapter:`create`,label:`Start in Profile`,caption:`Open Profile, choose Agent, and start the guided creation flow.`,placement:`bottom-left`,narration:`Open Profile, choose Agent, and start the guided creation flow.`,focus:{x:.84,y:.06,width:.145,height:.31,zoom:1.55}},{id:`C02`,file:`C02-source-choice-wide.png`,chapter:`create`,label:`Start from a prompt or chats`,caption:`Choose From prompt to describe the Agent directly, or From chats to include examples of the work it should handle.`,placement:`bottom-left`,narration:`Choose From prompt to describe the Agent directly, or From chats to include examples of the work it should handle.`,focus:{x:.31,y:.34,width:.38,height:.31,zoom:1.42}},{id:`C04`,file:`C04-from-chats-wide.png`,chapter:`create`,label:`Add purpose and chats`,caption:`This synthetic example starts with three chats: Acme has renewal blockers, Northstar is expanding, and the team needs a weekly account review. Add them with the Agent purpose.`,placement:`top-left`,narration:`This synthetic example starts with three chats: Acme has renewal blockers, Northstar is expanding, and the team needs a weekly account review. Add them with the Agent purpose.`,focus:{x:.31,y:.2,width:.38,height:.6,zoom:1.32}},{id:`C06`,file:`C06-disclosure.png`,chapter:`create`,label:`See how chats build the plan`,caption:`Review the selected excerpts as examples. OpenPond turns their recurring goals, decisions, corrections, and answer patterns into the first Agent plan.`,placement:`bottom-left`,narration:`Review the selected excerpts as examples. OpenPond turns their recurring goals, decisions, corrections, and answer patterns into the first Agent plan.`,focus:{x:.31,y:.2,width:.38,height:.6,zoom:1.32}},{id:`C07`,file:`C07-agent-review.png`,chapter:`create`,label:`Review the Agent`,caption:`The draft converts those examples into the Agent's purpose, chat behavior, runnable actions, output formats, and Evals for your review.`,placement:`bottom-left`,narration:`The draft converts those examples into the Agent's purpose, chat behavior, runnable actions, output formats, and Evals for your review.`,focus:{x:.31,y:.04,width:.38,height:.76,zoom:1.27}},{id:`C08`,file:`C08-right-chat-question.png`,chapter:`create`,label:`Answer the planning question`,caption:`The right side panel asks how the Agent should prioritize conflicting account risks.`,placement:`top-left`,narration:`The right side panel asks how the Agent should prioritize conflicting account risks.`,focus:{x:.715,y:.19,width:.265,height:.72,zoom:1.42}},{id:`C09`,file:`C09-right-chat-plan.png`,chapter:`create`,label:`Confirm the plan`,caption:`Before creation, review the proposed name, chat endpoint, runnable actions, Evals, and output formats.`,placement:`top-left`,narration:`Before creation, review the proposed name, chat endpoint, runnable actions, Evals, and output formats.`,focus:{x:.715,y:.18,width:.265,height:.72,zoom:1.42}},{id:`C09A`,file:`C09A-edit-plan.png`,chapter:`create`,label:`Edit the plan`,caption:`If the plan misses a requirement, open Edit plan and describe the change in plain language before any Agent source is created.`,placement:`top-left`,narration:`If the plan misses a requirement, open Edit plan and describe the change in plain language before any Agent source is created.`,focus:{x:.73,y:.66,width:.24,height:.24,zoom:1.45}},{id:`C09B`,file:`C09B-revised-plan.png`,chapter:`create`,label:`Create from the revised plan`,caption:`Review the revised plan, then click Confirm plan to create the Agent and run its Evals.`,placement:`top-left`,narration:`Review the revised plan, then click Confirm plan to create the Agent and run its Evals.`,focus:{x:.72,y:.7,width:.25,height:.2,zoom:1.45}},{id:`C10`,file:`C10-candidate-evaluation.png`,chapter:`create`,label:`Review the Evals`,caption:`This is the creation result: OpenPond built the Agent and passed its behavior Evals against the Account Health examples.`,placement:`bottom-left`,narration:`This is the creation result: OpenPond built the Agent and passed its behavior Evals against the Account Health examples.`,focus:{x:.19,y:.18,width:.5,height:.22,zoom:1.36}},{id:`C11`,file:`C11-local-source-applied.png`,chapter:`create`,label:`Save the Agent`,caption:`After the Evals pass, the Agent is saved to your Profile and is ready to use.`,placement:`bottom-left`,narration:`After the Evals pass, the Agent is saved to your Profile and is ready to use.`,focus:{x:.19,y:.16,width:.5,height:.14,zoom:1.38}},{id:`C12`,file:`C12-ready-local-detail.png`,chapter:`create`,label:`Use the Agent`,caption:`The Agent page shows its purpose, chat entrypoint, and runnable account actions.`,placement:`bottom-left`,narration:`The Agent page shows its purpose, chat entrypoint, and runnable account actions.`,focus:{x:.19,y:.17,width:.5,height:.13,zoom:1.38}},{id:`C13Q`,file:`C13Q-chat-acme-prompt.png`,chapter:`use`,label:`Ask the chat endpoint`,caption:`Use opens a normal chat with the Agent attached. Type a natural-language question about Acme before sending it.`,placement:`top-left`,narration:`Use opens a normal chat with the Agent attached. Type a natural-language question about Acme before sending it.`,focus:{x:.245,y:.84,width:.39,height:.14,zoom:1.48}},{id:`C13`,file:`C13-chat-acme.png`,chapter:`use`,label:`Ask about Acme`,caption:`Acme is the at-risk example: the Agent answers in chat with renewal timing, usage decline, the disputed invoice, and the open P1 case.`,placement:`top-left`,narration:`Acme is the at-risk example: the Agent answers in chat with renewal timing, usage decline, the disputed invoice, and the open P1 case.`,focus:{x:.2,y:.08,width:.48,height:.32,zoom:1.34}},{id:`C14`,file:`C14-chat-follow-up.png`,chapter:`use`,label:`Ask a follow-up`,caption:`A follow-up keeps Acme context and assigns the first actions to Revenue Operations and Support instead of restarting the conversation.`,placement:`top-left`,narration:`A follow-up keeps Acme context and assigns the first actions to Revenue Operations and Support instead of restarting the conversation.`,focus:{x:.2,y:.08,width:.48,height:.36,zoom:1.32}},{id:`C15`,file:`C15-action-picker.png`,chapter:`use`,label:`Choose a direct action`,caption:`The action picker offers chat plus each runnable account action, so you can choose conversation or a focused task.`,placement:`top-left`,narration:`The action picker offers chat plus each runnable account action, so you can choose conversation or a focused task.`,focus:{x:.245,y:.84,width:.39,height:.14,zoom:1.48}},{id:`C16`,file:`C16-northstar-summary.png`,chapter:`use`,label:`Summarize Northstar`,caption:`Northstar is the healthy expansion example from the source chats. Its direct summary identifies rising usage and the request for twenty-five more seats.`,placement:`top-left`,narration:`Northstar is the healthy expansion example from the source chats. Its direct summary identifies rising usage and the request for twenty-five more seats.`,focus:{x:.2,y:.37,width:.48,height:.2,zoom:1.38}},{id:`C17`,file:`C17-acme-triage.png`,chapter:`use`,label:`Triage Acme`,caption:`Running renewal triage for Acme returns high risk, cites the billing and support blockers, and orders the next steps.`,placement:`top-left`,narration:`Running renewal triage for Acme returns high risk, cites the billing and support blockers, and orders the next steps.`,focus:{x:.2,y:.57,width:.48,height:.15,zoom:1.4}},{id:`C18`,file:`C18-weekly-review-artifacts.png`,chapter:`use`,label:`Build the weekly review`,caption:`The weekly review action combines the portfolio and returns visible Markdown, CSV, and JSON artifacts for downstream use.`,placement:`top-left`,narration:`The weekly review action combines the portfolio and returns visible Markdown, CSV, and JSON artifacts for downstream use.`,focus:{x:.2,y:.68,width:.48,height:.19,zoom:1.36}},{id:`C19`,file:`C19-after-restart.png`,chapter:`use`,label:`Verify persistence`,caption:`After restarting OpenPond, the same Agent, chat history, and actions remain available.`,placement:`bottom-left`,narration:`After restarting OpenPond, the same Agent, chat history, and actions remain available.`,focus:{x:.19,y:.16,width:.5,height:.15,zoom:1.38}},{id:`I00`,file:`I00-current-priority-gap.png`,chapter:`improve`,label:`Identify the behavior gap`,caption:`The current Agent finds the right facts, but buries the priority after the account summary. Improve will make the billing and P1 decision lead every high-risk result.`,placement:`top-left`,narration:`The current Agent finds the right facts, but buries the priority after the account summary. Improve will make the billing and P1 decision lead every high-risk result.`,focus:{x:.38,y:.06,width:.42,height:.18,zoom:1.4}},{id:`I01`,file:`I01-improve-source-choice.png`,chapter:`improve`,label:`Start Improve`,caption:`Open Improve agent on the existing Agent, then choose whether to describe the correction directly or include a chat that demonstrates it.`,placement:`bottom-left`,narration:`Open Improve agent on the existing Agent, then choose whether to describe the correction directly or include a chat that demonstrates it.`,focus:{x:.31,y:.34,width:.38,height:.31,zoom:1.42}},{id:`I02`,file:`I02-improve-from-chats.png`,chapter:`improve`,label:`Add the correction chat`,caption:`Choose From chats, ask every high-risk response to lead with the billing and P1 decision, and attach the correction conversation that demonstrates it.`,placement:`top-left`,narration:`Choose From chats, ask every high-risk response to lead with the billing and P1 decision, and attach the correction conversation that demonstrates it.`,focus:{x:.31,y:.2,width:.38,height:.6,zoom:1.32}},{id:`I03`,file:`I03-improve-review.png`,chapter:`improve`,label:`Review the improvement`,caption:`Review the new lead-with-priority behavior, the existing capabilities that must stay intact, and the Evals OpenPond will rerun.`,placement:`bottom-left`,narration:`Review the new lead-with-priority behavior, the existing capabilities that must stay intact, and the Evals OpenPond will rerun.`,focus:{x:.31,y:.04,width:.38,height:.76,zoom:1.27}},{id:`I04`,file:`I04-improve-right-chat-plan.png`,chapter:`improve`,label:`Confirm the Improve plan`,caption:`Review the planned change and confirm that it preserves citations and every existing action.`,placement:`top-left`,narration:`Review the planned change and confirm that it preserves citations and every existing action.`,focus:{x:.715,y:.18,width:.265,height:.72,zoom:1.42}},{id:`I05`,file:`I05-improve-comparison.png`,chapter:`improve`,label:`Compare the results`,caption:`The same locked Evals make the decision clear: the current Agent misses the new lead sentence, while the updated Agent passes every original and new Eval.`,placement:`bottom-left`,narration:`The same locked Evals make the decision clear: the current Agent misses the new lead sentence, while the updated Agent passes every original and new Eval.`,focus:{x:.745,y:.8,width:.22,height:.13,zoom:1.5}},{id:`I06`,file:`I06-improved-release.png`,chapter:`improve`,label:`Save the improvement`,caption:`Apply the update only after that comparison. The existing Agent updates in place, with the successful Evals recorded.`,placement:`bottom-left`,narration:`Apply the update only after that comparison. The existing Agent updates in place, with the successful Evals recorded.`,focus:{x:.71,y:.16,width:.28,height:.22,zoom:1.45}},{id:`I07`,file:`I07-improved-chat.png`,chapter:`improve`,label:`Verify improved chat`,caption:`The improved chat now places disputed billing and the open P1 case ahead of adoption decline while preserving source citations.`,placement:`top-left`,narration:`The improved chat now places disputed billing and the open P1 case ahead of adoption decline while preserving source citations.`,focus:{x:.2,y:.08,width:.48,height:.16,zoom:1.4}},{id:`I08`,file:`I08-improved-triage.png`,chapter:`improve`,label:`Verify improved triage`,caption:`The direct triage action repeats the billing-first result, proving the change works outside chat without breaking the existing workflow.`,placement:`top-left`,narration:`The direct triage action repeats the billing-first result, proving the change works outside chat without breaking the existing workflow.`,focus:{x:.2,y:.27,width:.48,height:.16,zoom:1.4}},{id:`I09`,file:`I09-profile-commit-dialog.png`,chapter:`improve`,label:`Commit the Profile source`,caption:`Commit the final Agent source with a clear Git message so the exact Profile version remains reviewable and shareable.`,placement:`bottom-left`,narration:`Commit the final Agent source with a clear Git message so the exact Profile version remains reviewable and shareable.`,focus:{x:.37,y:.36,width:.26,height:.29,zoom:1.45}},{id:`I10`,file:`I10-profile-sync-dialog.png`,chapter:`improve`,label:`Review the hosted sync`,caption:`Open Sync to review the committed Profile changes. Confirm sync publishes this version so teammates can use the Agent in chat and hosted sandboxes can attach the same source.`,placement:`bottom-left`,narration:`Open Sync to review the committed Profile changes. Confirm sync publishes this version so teammates can use the Agent in chat and hosted sandboxes can attach the same source.`,focus:{x:.5,y:.61,width:.11,height:.07,zoom:1.55}}],frameMinimumDuration:5.2,focusStyle:{borderColor:`#22d3ee`,borderWidth:5,dimOpacity:.32,zoomDelaySeconds:.8,zoomDurationSeconds:1.2}},se=w(`how-to-make-an-agent`),O=D.chapters,ce={create:`1:24`,use:`1:05`,improve:`1:10`},k=se.title,le=D.tutorial.title,A=`4:33`,j={captionsUrl:l,chapterIds:O.map(e=>e.id),description:`Create, use, and improve an Account Health Agent in one continuous walkthrough.`,duration:A,eyebrow:`Play all`,id:`make-agent-tutorial`,lessonNumber:null,posterUrl:o,title:le,videoId:`play-all`,videoUrl:ae},M=O.map((e,t)=>({captionsUrl:u(e.id),chapterIds:[e.id],description:e.subtitle,duration:ce[e.id],eyebrow:`Lesson ${t+1}`,id:`make-agent-tutorial-${e.id}`,lessonNumber:t+1,posterUrl:n(e.id),title:e.title,videoId:e.id,videoUrl:oe(e.id)})),ue=[j,...M];function N(e){return ue.find(t=>t.videoId===e)??j}function de(e){let t=M.findIndex(t=>t.videoId===e);return t<0?null:M[t+1]?.videoId??null}var fe=[2,1,0];function pe({activeVideoId:e=`play-all`,autoplay:t=!0,onClose:n,onOpen:r,onSelectVideo:i,open:a=!1,playRequestId:o=0}={}){let s=(0,v.useRef)(null),c=N(e);(0,v.useEffect)(()=>{if(!a)return;let e=s.current;e&&(e.load(),o>0&&e.play().catch(()=>void 0))},[c.id,a,o]);function l(){if(!t||!i)return;let n=de(e);n&&i(n)}return(0,y.jsxs)(`section`,{className:`get-started-series`,"aria-label":k,children:[(0,y.jsxs)(`article`,{className:`get-started-playlist-card`,"aria-labelledby":`make-agent-series-title`,children:[(0,y.jsx)(`button`,{"aria-haspopup":`dialog`,"aria-label":`Open ${k} playlist`,className:`get-started-playlist-open`,onClick:r,type:`button`}),(0,y.jsxs)(`div`,{className:`get-started-playlist-stack`,"aria-hidden":`true`,children:[fe.map((e,t)=>{let n=M[e];return(0,y.jsx)(`div`,{className:`get-started-playlist-poster layer-${t+1}`,children:(0,y.jsx)(`img`,{alt:``,decoding:`async`,src:n.posterUrl})},n.id)}),(0,y.jsx)(`span`,{className:`get-started-course-play-icon`,children:(0,y.jsx)(m,{fill:`currentColor`,size:19})}),(0,y.jsxs)(`span`,{className:`get-started-playlist-count`,children:[M.length,` lessons`]})]}),(0,y.jsxs)(`div`,{className:`get-started-playlist-copy`,children:[(0,y.jsx)(`h1`,{id:`make-agent-series-title`,children:k}),(0,y.jsxs)(`div`,{className:`get-started-course-meta`,children:[(0,y.jsx)(`span`,{children:`Walkthrough playlist`}),(0,y.jsx)(`span`,{"aria-hidden":`true`,children:`·`}),(0,y.jsx)(`span`,{children:A})]}),(0,y.jsx)(`p`,{children:`Create, use, and improve an Account Health Agent, or play the full walkthrough.`})]})]}),a&&n&&i?(0,y.jsx)(me,{activeVideoId:e,autoplay:t,contained:!0,inertExclusionSelector:`.get-started-learning-panel`,onClose:n,onEnded:l,onSelectVideo:i,videoRef:s}):null]})}function me({activeVideoId:e=`play-all`,autoplay:t=!0,contained:n=!1,inertExclusionSelector:r,onClose:i,onEnded:a,onSelectVideo:o=()=>void 0,videoRef:s}){let c=N(e),l=M.findIndex(t=>t.videoId===e),u=l>=0?M[l+1]?.videoId:void 0,d=l>0?M[l-1]?.videoId:void 0;return(0,y.jsx)(b,{autoAdvance:t&&l>=0,contained:n,inertExclusionSelector:r,navigation:l>=0?{currentIndex:l,onNext:u?()=>o(u):void 0,onPrevious:d?()=>o(d):void 0,total:M.length}:void 0,onClose:i,onEnded:a?()=>a():void 0,video:c,videoRef:s})}var P=w(`post-training-from-first-principles`),F=P.title,he=P.status;function I(e,t,n,i,a,o){let s=`courses/post-training/${t}`,c=`post-training-${t}`;return{captionsUrl:r(`${s}.vtt`),description:o,duration:a,eyebrow:i,id:c,lessonNumber:e,posterUrl:r(`${s}-poster.webp`),slug:t,title:n,videoUrl:T(c)}}var L=[I(1,`01-how-post-training-works`,`How post-training works`,`Start here`,`1:05`,`The choose, judge, and update loop behind every method in this series.`),I(2,`02-definitions`,`Definitions`,`Reference`,`6:14`,`Policy notation, softmax, rollouts, advantages, gradients, GRPO, and the acronyms used throughout the series.`),I(3,`03-on-policy-off-policy`,`On-policy and off-policy data`,`Data source`,`1:06`,`Why learner rollouts and teacher or stored data support different updates.`),I(4,`04-rewards-credit-assignment`,`Rewards and credit assignment`,`RL foundation`,`3:00`,`Follow a code-repair trajectory from actions and observations to advantage.`),I(5,`05-verifiable-rewards-rlvr`,`Verifiable rewards`,`RLVR`,`2:53`,`See how tests create scalable rewards—and how a model can exploit the checker.`),I(6,`06-ppo-grpo`,`PPO and GRPO`,`Policy updates`,`2:54`,`Compare PPO's learned critic with GRPO's sibling-response baseline.`),I(7,`07-distillation`,`Distillation`,`Teacher targets`,`2:42`,`Transfer a teacher's token distribution instead of copying one final answer.`),I(8,`08-opsd-sdft-sdpo`,`OPSD, SDFT, and SDPO`,`Teacher evidence`,`2:43`,`Compare trusted solutions, demonstrations, and failure feedback at one prefix.`),I(9,`09-credible-experiments`,`Credible experiments`,`Research design`,`3:32`,`Build versioned datasets, fair baselines, and claims that survive scrutiny.`),I(10,`10-technical-appendix`,`Technical appendix`,`Advanced details`,`3:12`,`Inspect GRPO normalization, compressed teacher logits, reported method results, and sample routing.`)],ge=`29 min`,R=P.fullVideoId;if(!R)throw Error(`Post-training playlist is missing its full video`);var z={captionsUrl:r(`courses/post-training/full-course.vtt`),description:`All ten lessons in one continuous video for watching, sharing, or uploading.`,duration:`29:20`,eyebrow:`Full course`,id:R,posterUrl:r(`courses/post-training/full-course-poster.webp`),title:F,videoUrl:T(R)};function B(e){let t=e+1;return t<L.length?t:null}var V=`Subject to change, lesson work in progress`;function _e(){let e=he===`draft`?`Draft`:`Published`;return(0,y.jsx)(`span`,{"aria-label":`${e}: ${V}`,className:`get-started-playlist-status app-tooltip`,"data-tooltip":V,tabIndex:0,children:e})}var H=`openpond.post-training-progress.v1`,U=Object.freeze({}),ve=1e3,W=new Set,G=null,K=null,q=!1;function J(e){return typeof e==`number`&&Number.isFinite(e)?e:null}function ye(e){if(!e||typeof e!=`object`||Array.isArray(e))return U;let t={};for(let[n,r]of Object.entries(e)){if(!n||!r||typeof r!=`object`||Array.isArray(r))continue;let e=r,i=J(e.duration),a=J(e.currentTime),o=J(e.updatedAt);if(i===null||i<=0||a===null)continue;let s=e.completed===!0;t[n]={completed:s,currentTime:s?i:Math.min(i,Math.max(0,a)),duration:i,updatedAt:o===null?0:Math.max(0,o)}}return Object.keys(t).length>0?t:U}function be(e){if(!e)return U;try{return ye(JSON.parse(e))}catch{return U}}function Y(){if(typeof window>`u`)return U;try{return be(f.getItem(H))}catch{return U}}function X(){if(typeof window<`u`&&K!==null&&window.clearTimeout(K),K=null,typeof window<`u`&&G!==null)try{f.setItem(H,JSON.stringify(G))}catch{}}function xe(){typeof window<`u`&&K===null&&(K=window.setTimeout(X,ve))}function Se(){typeof window>`u`||q||(q=!0,window.addEventListener(`pagehide`,X),d(()=>{G=Y(),W.forEach(e=>e())}))}function Z(){return G===null&&(G=Y()),Se(),G}function Q({completed:e=!1,currentTime:t,duration:n,lessonId:r}){if(!r||!Number.isFinite(n)||n<=0||!Number.isFinite(t))return;let i=Z(),a=i[r],o=!!(a?.completed||e),s=o?n:Math.min(n,Math.max(0,t));a&&a.completed===o&&Math.abs(a.currentTime-s)<.25&&Math.abs(a.duration-n)<.25||(G={...i,[r]:{completed:o,currentTime:s,duration:n,updatedAt:Date.now()}},xe(),W.forEach(e=>e()))}function Ce(e){return!e||e.completed||e.currentTime<1?0:e.currentTime<e.duration-2?e.currentTime:0}var $=F,we=[2,1,0];function Te({activeLessonIndex:e,fullCourseSelected:t=!1,autoplay:n=!0,open:r,onClose:i,onOpen:a,onSelectLesson:o,playRequestId:s=0}){let c=(0,v.useRef)(null),l=(0,v.useRef)(null),u=L[e]??L[0],d=t?z:u;(0,v.useEffect)(()=>{if(!r)return;let e=c.current;if(!e)return;let t=!1;l.current=null,e.load();let n=()=>{if(t)return;let n=Ce(Z()[d.id]);n>0&&(e.currentTime=n),s>0&&e.play().catch(()=>void 0)};return e.readyState>=HTMLMediaElement.HAVE_METADATA?n():e.addEventListener(`loadedmetadata`,n,{once:!0}),()=>{t=!0,e.removeEventListener(`loadedmetadata`,n),Number.isFinite(e.duration)&&e.duration>0&&e.currentTime>0&&Q({completed:e.ended,currentTime:e.currentTime,duration:e.duration,lessonId:d.id})}},[d.id,r,s]);function f(e,t=!1){!Number.isFinite(e.duration)||e.duration<=0||Q({completed:t,currentTime:t?e.duration:e.currentTime,duration:e.duration,lessonId:d.id})}function p(e){if(!Number.isFinite(e.duration)||e.duration<=0)return;let t=Math.min(99,Math.floor(e.currentTime/e.duration*100)),n=l.current;(n?.lessonId!==d.id||n.percent!==t)&&(l.current={lessonId:d.id,percent:t},f(e))}function h(e){f(e,!0),n&&!t&&g()}function g(){let t=B(e);t!==null&&o(t)}return(0,y.jsxs)(`section`,{className:`get-started-series`,"aria-label":$,children:[(0,y.jsxs)(`article`,{className:`get-started-playlist-card`,"aria-labelledby":`post-training-series-title`,children:[(0,y.jsx)(`button`,{"aria-haspopup":`dialog`,"aria-label":`Open ${$} playlist`,className:`get-started-playlist-open`,onClick:a,type:`button`}),(0,y.jsxs)(`div`,{className:`get-started-playlist-stack`,"aria-hidden":`true`,children:[we.map((e,t)=>{let n=L[e];return(0,y.jsx)(`div`,{className:`get-started-playlist-poster layer-${t+1}`,children:(0,y.jsx)(`img`,{alt:``,decoding:`async`,src:n.posterUrl})},n.id)}),(0,y.jsx)(`span`,{className:`get-started-course-play-icon`,children:(0,y.jsx)(m,{fill:`currentColor`,size:19})}),(0,y.jsxs)(`span`,{className:`get-started-playlist-count`,children:[L.length,` lessons`]})]}),(0,y.jsxs)(`div`,{className:`get-started-playlist-copy`,children:[(0,y.jsxs)(`div`,{className:`get-started-playlist-title`,children:[(0,y.jsx)(`h1`,{id:`post-training-series-title`,children:$}),(0,y.jsx)(_e,{})]}),(0,y.jsxs)(`div`,{className:`get-started-course-meta`,children:[(0,y.jsx)(`span`,{children:`Learning series`}),(0,y.jsx)(`span`,{"aria-hidden":`true`,children:`·`}),(0,y.jsx)(`span`,{children:ge})]}),(0,y.jsx)(`p`,{children:`Rewards, GRPO, RLVR, distillation, experiments, and a technical appendix.`})]})]}),r?(0,y.jsx)(Ee,{activeLessonIndex:e,autoplay:n,fullCourseSelected:t,onClose:i,onEnded:h,onPause:f,onSelectLesson:o,onTimeUpdate:p,videoRef:c}):null]})}function Ee({activeLessonIndex:e,autoplay:t,fullCourseSelected:n,onClose:r,onEnded:i,onPause:a,onSelectLesson:o,onTimeUpdate:s,videoRef:c}){let l=L[e]??L[0],u=B(e),d=n?z:l;return(0,y.jsx)(b,{autoAdvance:t&&!n,contained:!0,inertExclusionSelector:`.get-started-learning-panel`,navigation:n?void 0:{currentIndex:e,onNext:u===null?void 0:()=>o(u),onPrevious:e>0?()=>o(e-1):void 0,total:L.length},onClose:r,onEnded:i,onPause:a,onTimeUpdate:s,video:d,videoRef:c})}var De={captionsUrl:t,description:`See how Profile Agents combine chat, direct actions, shared runtime surfaces, and Evals.`,duration:`1:16`,eyebrow:`Agent overview`,id:`openpond-agent-overview`,posterUrl:c,title:`What is an OpenPond Agent?`,videoUrl:E};function Oe(e={}){let[t,n]=(0,v.useState)(null),[r,i]=(0,v.useState)(null),a=e.makeAgentTutorial===void 0?t:e.makeAgentTutorial,o=e.postTrainingCourse===void 0?r:e.postTrainingCourse,s=!!(o||a);function c(){e.onOpenMakeAgentTutorial?e.onOpenMakeAgentTutorial():(i(null),n({autoplay:!0,playRequestId:0,videoId:`create`}))}function l(){e.onCloseMakeAgentTutorial?e.onCloseMakeAgentTutorial():n(null)}function u(t){e.onSelectMakeAgentTutorialVideo?e.onSelectMakeAgentTutorialVideo(t):n(e=>e&&{...e,playRequestId:e.playRequestId+1,videoId:t})}function d(){e.onOpenPostTrainingCourse?e.onOpenPostTrainingCourse():(n(null),i({autoplay:!0,fullCourseSelected:!1,lessonIndex:0,playRequestId:0}))}function f(){e.onClosePostTrainingCourse?e.onClosePostTrainingCourse():i(null)}function p(t){e.onSelectPostTrainingLesson?e.onSelectPostTrainingLesson(t):i(e=>e&&{...e,fullCourseSelected:!1,lessonIndex:t,playRequestId:e.playRequestId+1})}return(0,y.jsx)(`section`,{className:`get-started-view ${s?`course-player-open`:``}`,"aria-label":`Walkthroughs`,children:(0,y.jsxs)(`div`,{className:`get-started-shell`,children:[(0,y.jsxs)(`section`,{className:`get-started-start-here`,"aria-labelledby":`get-started-start-here-title`,children:[(0,y.jsx)(`header`,{className:`get-started-section-heading`,children:(0,y.jsx)(`h2`,{id:`get-started-start-here-title`,children:`Start here`})}),(0,y.jsx)(`div`,{className:`get-started-learning-grid`,children:(0,y.jsx)(te,{titleElement:`h1`,video:De})})]}),(0,y.jsxs)(`section`,{className:`get-started-walkthroughs`,"aria-labelledby":`get-started-walkthroughs-title`,children:[(0,y.jsx)(`header`,{className:`get-started-section-heading`,children:(0,y.jsx)(`h2`,{id:`get-started-walkthroughs-title`,children:`Walkthroughs`})}),(0,y.jsx)(`div`,{className:`get-started-learning-grid`,children:(0,y.jsx)(pe,{activeVideoId:a?.videoId??`create`,autoplay:a?.autoplay??!0,onClose:l,onOpen:c,onSelectVideo:u,open:!!a,playRequestId:a?.playRequestId??0})})]}),(0,y.jsxs)(`section`,{className:`get-started-learn`,"aria-labelledby":`get-started-learn-title`,children:[(0,y.jsx)(`header`,{className:`get-started-section-heading`,children:(0,y.jsx)(`h2`,{id:`get-started-learn-title`,children:`Learn deeper`})}),(0,y.jsx)(`div`,{className:`get-started-learning-grid`,children:(0,y.jsx)(Te,{activeLessonIndex:o?.lessonIndex??0,autoplay:o?.autoplay??!0,fullCourseSelected:o?.fullCourseSelected??!1,open:!!o,onClose:f,onOpen:d,onSelectLesson:p,playRequestId:o?.playRequestId??0})})]})]})})}export{Oe as GetStartedView};
|