foxclaw 0.1.0 → 0.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +54 -29
- package/bin/foxclaw.cjs +51 -0
- package/index.js +4 -10
- package/package.json +46 -38
- package/python/.dockerignore +35 -0
- package/python/.env.example +173 -0
- package/python/.gitattributes +46 -0
- package/python/.github/workflows/ci.yml +167 -0
- package/python/.github/workflows/release.yml +183 -0
- package/python/CHANGELOG.md +57 -0
- package/python/CHANGELOG_CN.md +57 -0
- package/python/Dockerfile +64 -0
- package/python/LICENSE +21 -0
- package/python/MANIFEST.in +14 -0
- package/python/README.md +201 -0
- package/python/README_CN.md +336 -0
- package/python/bench/bm25_audit.py +186 -0
- package/python/bench/bm25_regression.py +177 -0
- package/python/bench/bm25_stress.py +155 -0
- package/python/bench/cd_audit.py +215 -0
- package/python/bench/chaos.py +140 -0
- package/python/bench/concurrency.py +103 -0
- package/python/bench/e2e_real_models.py +94 -0
- package/python/bench/llm_retry_test.py +241 -0
- package/python/bench/load_test.py +193 -0
- package/python/bench/vector_ivf_upgrade.py +128 -0
- package/python/docs/CHANNELS.md +195 -0
- package/python/docs/GOVERNANCE.md +164 -0
- package/python/docs/RELEASE.md +110 -0
- package/python/docs/RUN.md +75 -0
- package/python/docs/RUN_CN.md +121 -0
- package/python/docs//351/205/215/347/275/256/346/214/207/345/215/227.md +152 -0
- package/python/evals/__init__.py +0 -0
- package/python/evals/governance/README.md +61 -0
- package/python/evals/governance/__init__.py +0 -0
- package/python/evals/governance/cases.py +115 -0
- package/python/evals/governance/compare_embeddings.py +94 -0
- package/python/evals/governance/convergence.svg +11 -0
- package/python/evals/governance/report.json +371 -0
- package/python/evals/governance/run_evals.py +368 -0
- package/python/examples/governance_middleware_demo.py +72 -0
- package/python/examples/langgraph_governance_demo.py +104 -0
- package/python/examples/sample_itinerary.csv +6 -0
- package/python/examples/sample_knowledge.csv +9 -0
- package/python/examples/sample_transactions.csv +14 -0
- package/python/foxclaw/__init__.py +408 -0
- package/python/foxclaw/agents/__init__.py +12 -0
- package/python/foxclaw/agents/agents.py +35 -0
- package/python/foxclaw/agents/base.py +794 -0
- package/python/foxclaw/agents/impl/__init__.py +1 -0
- package/python/foxclaw/agents/impl/_helpers.py +70 -0
- package/python/foxclaw/agents/impl/finance.py +231 -0
- package/python/foxclaw/agents/impl/office.py +350 -0
- package/python/foxclaw/agents/impl/supervisor.py +592 -0
- package/python/foxclaw/agents/mixins/_context.py +128 -0
- package/python/foxclaw/agents/mixins/augment.py +143 -0
- package/python/foxclaw/agents/mixins/llm.py +67 -0
- package/python/foxclaw/agents/mixins/memory.py +41 -0
- package/python/foxclaw/agents/mixins/preference.py +131 -0
- package/python/foxclaw/agents/mixins/prompt.py +71 -0
- package/python/foxclaw/agents/mixins/skillbox.py +58 -0
- package/python/foxclaw/agents/mixins/tool_exec.py +417 -0
- package/python/foxclaw/api/__init__.py +224 -0
- package/python/foxclaw/api/_state.py +43 -0
- package/python/foxclaw/api/bootstrap.py +96 -0
- package/python/foxclaw/api/middleware.py +294 -0
- package/python/foxclaw/api/routes/ahs.py +404 -0
- package/python/foxclaw/api/routes/attachments.py +116 -0
- package/python/foxclaw/api/routes/browser.py +35 -0
- package/python/foxclaw/api/routes/domain.py +306 -0
- package/python/foxclaw/api/routes/knowledge.py +145 -0
- package/python/foxclaw/api/routes/llm_admin.py +449 -0
- package/python/foxclaw/api/routes/memory.py +105 -0
- package/python/foxclaw/api/routes/orchestration.py +39 -0
- package/python/foxclaw/api/routes/recovery.py +44 -0
- package/python/foxclaw/api/routes/review.py +266 -0
- package/python/foxclaw/api/routes/search.py +33 -0
- package/python/foxclaw/api/routes/system.py +311 -0
- package/python/foxclaw/api/routes/task.py +263 -0
- package/python/foxclaw/api/routes/ws.py +64 -0
- package/python/foxclaw/api/spine.py +52 -0
- package/python/foxclaw/browser/__init__.py +13 -0
- package/python/foxclaw/browser/action/__init__.py +1 -0
- package/python/foxclaw/browser/action/action_executor.py +50 -0
- package/python/foxclaw/browser/action/action_types.py +44 -0
- package/python/foxclaw/browser/action/action_verifier.py +68 -0
- package/python/foxclaw/browser/action/url_policy.py +143 -0
- package/python/foxclaw/browser/adapter/__init__.py +1 -0
- package/python/foxclaw/browser/adapter/base_adapter.py +23 -0
- package/python/foxclaw/browser/adapter/web_adapter.py +46 -0
- package/python/foxclaw/browser/driver/__init__.py +1 -0
- package/python/foxclaw/browser/driver/base_driver.py +61 -0
- package/python/foxclaw/browser/driver/playwright_driver.py +170 -0
- package/python/foxclaw/browser/perception/__init__.py +1 -0
- package/python/foxclaw/browser/perception/dom_extractor.py +42 -0
- package/python/foxclaw/browser/perception/element_indexer.py +56 -0
- package/python/foxclaw/browser/perception/semantic_reducer.py +33 -0
- package/python/foxclaw/browser/perception/snapshot.py +29 -0
- package/python/foxclaw/browser/service.py +144 -0
- package/python/foxclaw/browser/session/__init__.py +1 -0
- package/python/foxclaw/browser/session/session_manager.py +57 -0
- package/python/foxclaw/capability/__init__.py +12 -0
- package/python/foxclaw/capability/embedding_service.py +65 -0
- package/python/foxclaw/channels/__init__.py +138 -0
- package/python/foxclaw/channels/discord.py +175 -0
- package/python/foxclaw/channels/dispatcher.py +179 -0
- package/python/foxclaw/channels/feishu.py +215 -0
- package/python/foxclaw/channels/openclaw_bridge.py +151 -0
- package/python/foxclaw/channels/signing.py +187 -0
- package/python/foxclaw/channels/telegram.py +120 -0
- package/python/foxclaw/channels/weixin.py +215 -0
- package/python/foxclaw/cli.py +183 -0
- package/python/foxclaw/cognitive/__init__.py +4 -0
- package/python/foxclaw/cognitive/reasoner.py +81 -0
- package/python/foxclaw/cognitive/state.py +141 -0
- package/python/foxclaw/core/__init__.py +9 -0
- package/python/foxclaw/core/audit_chain.py +131 -0
- package/python/foxclaw/core/audit_sink.py +100 -0
- package/python/foxclaw/core/compaction.py +265 -0
- package/python/foxclaw/core/config.py +65 -0
- package/python/foxclaw/core/confirm_nonce.py +151 -0
- package/python/foxclaw/core/dispatch.py +27 -0
- package/python/foxclaw/core/envfile.py +48 -0
- package/python/foxclaw/core/failure_policy.py +142 -0
- package/python/foxclaw/core/gateway.py +81 -0
- package/python/foxclaw/core/governance_audit.py +171 -0
- package/python/foxclaw/core/idempotency.py +282 -0
- package/python/foxclaw/core/injection_guard.py +202 -0
- package/python/foxclaw/core/memory_adapter.py +489 -0
- package/python/foxclaw/core/metrics.py +88 -0
- package/python/foxclaw/core/model_router.py +985 -0
- package/python/foxclaw/core/paths.py +103 -0
- package/python/foxclaw/core/recovery.py +349 -0
- package/python/foxclaw/core/scheduler.py +141 -0
- package/python/foxclaw/core/secrets.py +131 -0
- package/python/foxclaw/core/sessions.py +155 -0
- package/python/foxclaw/core/settings.py +414 -0
- package/python/foxclaw/core/shared_write.py +186 -0
- package/python/foxclaw/core/steering_queue.py +154 -0
- package/python/foxclaw/core/system_bus.py +84 -0
- package/python/foxclaw/core/thought_chain.py +316 -0
- package/python/foxclaw/core/token_meter.py +231 -0
- package/python/foxclaw/core/tools.py +164 -0
- package/python/foxclaw/core/tracing.py +375 -0
- package/python/foxclaw/core/truth_pipeline.py +110 -0
- package/python/foxclaw/core/update_check.py +149 -0
- package/python/foxclaw/core/vec_recall_adapter.py +477 -0
- package/python/foxclaw/core/verify.py +173 -0
- package/python/foxclaw/core/web_search.py +218 -0
- package/python/foxclaw/finance/__init__.py +15 -0
- package/python/foxclaw/finance/evidence.py +149 -0
- package/python/foxclaw/finance/fx.py +98 -0
- package/python/foxclaw/finance/graph.py +179 -0
- package/python/foxclaw/finance/models.py +146 -0
- package/python/foxclaw/finance/nlparse.py +515 -0
- package/python/foxclaw/finance/policy.py +301 -0
- package/python/foxclaw/finance/reasoner.py +121 -0
- package/python/foxclaw/finance/reasoning.py +319 -0
- package/python/foxclaw/finance/reconcile.py +175 -0
- package/python/foxclaw/finance/runtime.py +500 -0
- package/python/foxclaw/governance/__init__.py +24 -0
- package/python/foxclaw/governance/middleware.py +176 -0
- package/python/foxclaw/harness/__init__.py +17 -0
- package/python/foxclaw/harness/_base.py +66 -0
- package/python/foxclaw/harness/_policy.py +340 -0
- package/python/foxclaw/harness/drift.py +77 -0
- package/python/foxclaw/harness/event_bus.py +28 -0
- package/python/foxclaw/harness/harness.py +358 -0
- package/python/foxclaw/harness/loop_detection.py +145 -0
- package/python/foxclaw/itinerary/__init__.py +10 -0
- package/python/foxclaw/itinerary/amap_client.py +114 -0
- package/python/foxclaw/itinerary/models.py +80 -0
- package/python/foxclaw/itinerary/reasoner.py +96 -0
- package/python/foxclaw/itinerary/reasoning.py +168 -0
- package/python/foxclaw/itinerary/runtime.py +144 -0
- package/python/foxclaw/kernel/__init__.py +13 -0
- package/python/foxclaw/kernel/capabilities.py +72 -0
- package/python/foxclaw/kernel/policy_gate.py +108 -0
- package/python/foxclaw/kernel/process_manager.py +186 -0
- package/python/foxclaw/kernel/scheduler.py +125 -0
- package/python/foxclaw/kernel/sentinel.py +443 -0
- package/python/foxclaw/kernel/sentinel_client.py +243 -0
- package/python/foxclaw/kernel/spine.py +97 -0
- package/python/foxclaw/knowledge/__init__.py +360 -0
- package/python/foxclaw/knowledge/truth_crystallizer.py +89 -0
- package/python/foxclaw/learning/__init__.py +12 -0
- package/python/foxclaw/learning/knowledge_graph.py +144 -0
- package/python/foxclaw/learning/models.py +93 -0
- package/python/foxclaw/learning/reasoner.py +67 -0
- package/python/foxclaw/learning/runtime.py +351 -0
- package/python/foxclaw/learning/spaced_repetition.py +91 -0
- package/python/foxclaw/mcp_server.py +188 -0
- package/python/foxclaw/orchestration/__init__.py +167 -0
- package/python/foxclaw/pipeline/__init__.py +23 -0
- package/python/foxclaw/pipeline/cognitive_pipeline.py +429 -0
- package/python/foxclaw/pipeline/stage_meta.py +21 -0
- package/python/foxclaw/pipeline/supervisor_stages.py +201 -0
- package/python/foxclaw/planning/__init__.py +17 -0
- package/python/foxclaw/planning/llm_planner.py +232 -0
- package/python/foxclaw/planning/planner.py +94 -0
- package/python/foxclaw/search/__init__.py +24 -0
- package/python/foxclaw/search/agent_port.py +190 -0
- package/python/foxclaw/search/evidence.py +109 -0
- package/python/foxclaw/search/external_search.py +50 -0
- package/python/foxclaw/search/hkc_read_port.py +60 -0
- package/python/foxclaw/search/internal_search.py +71 -0
- package/python/foxclaw/search/models.py +127 -0
- package/python/foxclaw/search/planner.py +44 -0
- package/python/foxclaw/search/retriever.py +39 -0
- package/python/foxclaw/search/runtime.py +127 -0
- package/python/foxclaw/search/strategy.py +44 -0
- package/python/foxclaw/skills/__init__.py +559 -0
- package/python/foxclaw/skills/archive.py +111 -0
- package/python/foxclaw/skills/fetch.py +226 -0
- package/python/foxclaw/skills/hooks_spec.py +69 -0
- package/python/foxclaw/skills/install_cmd.py +216 -0
- package/python/foxclaw/skills/lifecycle.py +252 -0
- package/python/foxclaw/skills/markdown_skill.py +175 -0
- package/python/foxclaw/skills/markdown_store.py +39 -0
- package/python/foxclaw/skills/mcp_client.py +184 -0
- package/python/foxclaw/skills/mcp_store.py +40 -0
- package/python/foxclaw/skills/permission.py +145 -0
- package/python/foxclaw/skills/pipeline.py +354 -0
- package/python/foxclaw/skills/policy.py +74 -0
- package/python/foxclaw/skills/review.py +72 -0
- package/python/foxclaw/skills/store.py +57 -0
- package/python/frontend/assets/core_bg.jpg +0 -0
- package/python/frontend/deck/auth.js +25 -0
- package/python/frontend/deck/chat_model_picker.js +483 -0
- package/python/frontend/deck/domain.js +276 -0
- package/python/frontend/deck/main.js +1806 -0
- package/python/frontend/deck/markdown.js +44 -0
- package/python/frontend/deck/settings.js +307 -0
- package/python/frontend/deck/state.js +5 -0
- package/python/frontend/deck/util.js +4 -0
- package/python/frontend/deck/visuals.js +190 -0
- package/python/frontend/deck.css +855 -0
- package/python/frontend/deck.html +686 -0
- package/python/frontend/deck_v2.html +341 -0
- package/python/frontend/planet/index.html +266 -0
- package/python/frontend/planet/planet.css +579 -0
- package/python/frontend/planet/planet.js +1436 -0
- package/python/frontend/planet/vendor/three.core.min.js +6 -0
- package/python/frontend/planet/vendor/three.module.min.js +6 -0
- package/python/frontend/v3/assets/index-CQSBdxk4.js +34 -0
- package/python/frontend/v3/assets/index-D5nIsjms.css +1 -0
- package/python/frontend/v3/index.html +15 -0
- package/python/frontend/widget_runtime.js +252 -0
- package/python/frontend/widgets.js +639 -0
- package/python/frontend_src/index.html +14 -0
- package/python/frontend_src/package-lock.json +1376 -0
- package/python/frontend_src/package.json +19 -0
- package/python/frontend_src/src/App.vue +58 -0
- package/python/frontend_src/src/api.js +82 -0
- package/python/frontend_src/src/components/ChatDock.vue +365 -0
- package/python/frontend_src/src/components/ComposerMenu.vue +75 -0
- package/python/frontend_src/src/components/DocViewer.vue +162 -0
- package/python/frontend_src/src/components/Inspector.vue +235 -0
- package/python/frontend_src/src/components/LeftRail.vue +415 -0
- package/python/frontend_src/src/components/MenuPopover.vue +128 -0
- package/python/frontend_src/src/components/MessageStream.vue +389 -0
- package/python/frontend_src/src/components/ModelPicker.vue +350 -0
- package/python/frontend_src/src/components/QuickIngest.vue +112 -0
- package/python/frontend_src/src/components/Stage.vue +272 -0
- package/python/frontend_src/src/components/ToolMenu.vue +141 -0
- package/python/frontend_src/src/components/TopBar.vue +118 -0
- package/python/frontend_src/src/components/panels/ActivityPanel.vue +82 -0
- package/python/frontend_src/src/components/panels/AgentsPanel.vue +83 -0
- package/python/frontend_src/src/components/panels/KnowledgePanel.vue +425 -0
- package/python/frontend_src/src/components/panels/MemoryPanel.vue +117 -0
- package/python/frontend_src/src/components/panels/PanelBox.vue +50 -0
- package/python/frontend_src/src/components/panels/ReviewPanel.vue +292 -0
- package/python/frontend_src/src/components/panels/SettingsPanel.vue +358 -0
- package/python/frontend_src/src/components/panels/TasksPanel.vue +73 -0
- package/python/frontend_src/src/components/panels/ToolsPanel.vue +746 -0
- package/python/frontend_src/src/components/panels/UsagePanel.vue +105 -0
- package/python/frontend_src/src/lib/fmt.js +44 -0
- package/python/frontend_src/src/lib/i18n.js +53 -0
- package/python/frontend_src/src/lib/locales/en.js +173 -0
- package/python/frontend_src/src/lib/locales/zh.js +174 -0
- package/python/frontend_src/src/lib/md.js +190 -0
- package/python/frontend_src/src/main.js +9 -0
- package/python/frontend_src/src/stores/app.js +91 -0
- package/python/frontend_src/src/stores/chat.js +450 -0
- package/python/frontend_src/src/stores/model.js +96 -0
- package/python/frontend_src/src/stores/panels.js +289 -0
- package/python/frontend_src/src/stores/profile.js +31 -0
- package/python/frontend_src/src/stores/system.js +25 -0
- package/python/frontend_src/src/styles/base.css +138 -0
- package/python/frontend_src/src/styles/panel.css +117 -0
- package/python/frontend_src/src/styles/tokens.css +78 -0
- package/python/frontend_src/vite.config.js +39 -0
- package/python/pyproject.toml +268 -0
- package/python/requirements.txt +311 -0
- package/python/skills/README.md +123 -0
- package/python/skills/execution-contract/SKILL.md +30 -0
- package/python/skills/general-assistant/SKILL.md +34 -0
- package/python/skills/planner/SKILL.md +33 -0
- package/python/skills/schedule-itinerary/SKILL.md +35 -0
- package/python/skills/skill-composition/SKILL.md +31 -0
- package/python/skills/skill-guard/SKILL.md +67 -0
- package/python/skills/skill-memory/SKILL.md +50 -0
- package/python/skills/skill-router/SKILL.md +35 -0
- package/python/tests/conftest.py +54 -0
- package/python/tests/run_all.py +200 -0
- package/python/tests/test_agent_lifecycle.py +326 -0
- package/python/tests/test_ahs_p2.py +393 -0
- package/python/tests/test_anthropic_tools.py +192 -0
- package/python/tests/test_api.py +97 -0
- package/python/tests/test_api_auth.py +79 -0
- package/python/tests/test_api_host_guard.py +69 -0
- package/python/tests/test_attachments.py +151 -0
- package/python/tests/test_audit_chain.py +116 -0
- package/python/tests/test_audit_sink.py +130 -0
- package/python/tests/test_browser.py +149 -0
- package/python/tests/test_browser_request_guard.py +180 -0
- package/python/tests/test_capabilities.py +152 -0
- package/python/tests/test_channel_signing.py +185 -0
- package/python/tests/test_channel_trust.py +109 -0
- package/python/tests/test_channels.py +174 -0
- package/python/tests/test_cli.py +46 -0
- package/python/tests/test_compaction_toolpair.py +119 -0
- package/python/tests/test_config_layering.py +61 -0
- package/python/tests/test_confirm_nonce.py +186 -0
- package/python/tests/test_context_compaction_wiring.py +124 -0
- package/python/tests/test_dispatch.py +89 -0
- package/python/tests/test_domain_evals.py +334 -0
- package/python/tests/test_domain_import.py +72 -0
- package/python/tests/test_domain_reasoners.py +134 -0
- package/python/tests/test_e2e.py +161 -0
- package/python/tests/test_emb_cache.py +97 -0
- package/python/tests/test_embedding_singleton.py +87 -0
- package/python/tests/test_envfile.py +83 -0
- package/python/tests/test_evals_smoke.py +90 -0
- package/python/tests/test_event_spine.py +174 -0
- package/python/tests/test_evidence_semantic.py +88 -0
- package/python/tests/test_evidence_sse.py +94 -0
- package/python/tests/test_file_ingest.py +135 -0
- package/python/tests/test_finance.py +144 -0
- package/python/tests/test_finance_ledger.py +245 -0
- package/python/tests/test_finance_persist.py +174 -0
- package/python/tests/test_gateway.py +125 -0
- package/python/tests/test_governance.py +421 -0
- package/python/tests/test_governance_audit.py +324 -0
- package/python/tests/test_governance_middleware.py +137 -0
- package/python/tests/test_hkc.py +268 -0
- package/python/tests/test_hkc_index_build_manager.py +306 -0
- package/python/tests/test_hkc_manifest_reuse.py +294 -0
- package/python/tests/test_hkc_search_event_sync.py +482 -0
- package/python/tests/test_import_path_guard.py +155 -0
- package/python/tests/test_injection_guard.py +193 -0
- package/python/tests/test_integration.py +117 -0
- package/python/tests/test_itinerary.py +100 -0
- package/python/tests/test_kee_semantic.py +84 -0
- package/python/tests/test_kernel.py +212 -0
- package/python/tests/test_learning.py +101 -0
- package/python/tests/test_llm_admin.py +145 -0
- package/python/tests/test_llm_planner.py +344 -0
- package/python/tests/test_markdown_skills.py +62 -0
- package/python/tests/test_markdown_skills_openclaw.py +66 -0
- package/python/tests/test_mcp_connectors.py +97 -0
- package/python/tests/test_mcp_guardian_discovery.py +87 -0
- package/python/tests/test_mcp_no_memory.py +43 -0
- package/python/tests/test_mcp_policy_gate.py +76 -0
- package/python/tests/test_mcp_server.py +92 -0
- package/python/tests/test_memory_recall.py +92 -0
- package/python/tests/test_metrics.py +58 -0
- package/python/tests/test_multi_chain.py +90 -0
- package/python/tests/test_multimodal.py +122 -0
- package/python/tests/test_negotiation.py +136 -0
- package/python/tests/test_orchestration.py +109 -0
- package/python/tests/test_orchestration_decoupled.py +103 -0
- package/python/tests/test_p3_p5_hardening.py +324 -0
- package/python/tests/test_parallel_dispatch.py +207 -0
- package/python/tests/test_pipeline.py +492 -0
- package/python/tests/test_plan_visible.py +86 -0
- package/python/tests/test_planner.py +88 -0
- package/python/tests/test_policy_gate.py +108 -0
- package/python/tests/test_profile.py +67 -0
- package/python/tests/test_readme_claims.py +163 -0
- package/python/tests/test_reasoner.py +170 -0
- package/python/tests/test_release_check.py +252 -0
- package/python/tests/test_resume_checkpoint.py +148 -0
- package/python/tests/test_routing.py +85 -0
- package/python/tests/test_scheduler.py +138 -0
- package/python/tests/test_search.py +194 -0
- package/python/tests/test_secrets.py +153 -0
- package/python/tests/test_semantic.py +69 -0
- package/python/tests/test_sessions.py +90 -0
- package/python/tests/test_settings.py +265 -0
- package/python/tests/test_shadow_learning.py +290 -0
- package/python/tests/test_shared_write.py +200 -0
- package/python/tests/test_skill_taint_gate.py +145 -0
- package/python/tests/test_skills.py +117 -0
- package/python/tests/test_skills_fetch.py +282 -0
- package/python/tests/test_stats_and_events.py +162 -0
- package/python/tests/test_streaming.py +55 -0
- package/python/tests/test_supervisor_pipeline.py +176 -0
- package/python/tests/test_supervisor_triage.py +102 -0
- package/python/tests/test_taint.py +112 -0
- package/python/tests/test_task_stream.py +74 -0
- package/python/tests/test_thinking_sse.py +66 -0
- package/python/tests/test_thinking_stream.py +76 -0
- package/python/tests/test_tool_center.py +113 -0
- package/python/tests/test_tool_parallel.py +113 -0
- package/python/tests/test_tool_params.py +99 -0
- package/python/tests/test_tool_use.py +229 -0
- package/python/tests/test_toplevel_concurrency.py +116 -0
- package/python/tests/test_tracing.py +256 -0
- package/python/tests/test_truth_crystallizer.py +125 -0
- package/python/tests/test_truth_flow.py +88 -0
- package/python/tests/test_update_check.py +95 -0
- package/python/tests/test_url_policy.py +53 -0
- package/python/tests/test_verify_evidence.py +212 -0
- package/python/tests/test_version_sync.py +100 -0
- package/python/tests/test_web_trigger.py +82 -0
- package/python/tools/check_faiss_type.py +30 -0
- package/python/tools/check_log.ps1 +38 -0
- package/python/tools/ivf_status.py +72 -0
- package/python/tools/mypy_baseline.txt +13 -0
- package/python/tools/mypy_ratchet.py +143 -0
- package/python/tools/pack.py +173 -0
- package/python/tools/release_check.py +349 -0
- package/python/tools/restart_foxclaw.ps1 +71 -0
- package/python/tools/shared_write_audit.py +190 -0
- package/python/tools/size_baseline.txt +28 -0
- package/python/tools/size_check.py +102 -0
- package/python/tools/strip_comments.py +228 -0
- package/python/tools/verify_env.bat +2 -0
- package/python/tools/verify_env.py +25 -0
- package/python/vendor/HMR_LICENSE +37 -0
- package/python/vendor/HMR_README.md +65 -0
- package/python/vendor/hkc/LICENSE +37 -0
- package/python/vendor/hkc/hkc_ace/__init__.py +0 -0
- package/python/vendor/hkc/hkc_ace/ace.py +457 -0
- package/python/vendor/hkc/hkc_ace/skill_taxonomy.json +465 -0
- package/python/vendor/hkc/hkc_api/__init__.py +0 -0
- package/python/vendor/hkc/hkc_api/container.py +416 -0
- package/python/vendor/hkc/hkc_api/ingest_jobs.py +103 -0
- package/python/vendor/hkc/hkc_api/main.py +157 -0
- package/python/vendor/hkc/hkc_api/routes/__init__.py +0 -0
- package/python/vendor/hkc/hkc_api/routes/ability.py +151 -0
- package/python/vendor/hkc/hkc_api/routes/config.py +51 -0
- package/python/vendor/hkc/hkc_api/routes/knowledge.py +630 -0
- package/python/vendor/hkc/hkc_api/routes/search.py +88 -0
- package/python/vendor/hkc/hkc_api/schemas.py +153 -0
- package/python/vendor/hkc/hkc_api/synthesis.py +179 -0
- package/python/vendor/hkc/hkc_core/__init__.py +0 -0
- package/python/vendor/hkc/hkc_core/graph/__init__.py +0 -0
- package/python/vendor/hkc/hkc_core/graph/base.py +188 -0
- package/python/vendor/hkc/hkc_core/graph/sqlite_store.py +789 -0
- package/python/vendor/hkc/hkc_core/models/__init__.py +0 -0
- package/python/vendor/hkc/hkc_core/models/enums.py +65 -0
- package/python/vendor/hkc/hkc_core/models/ku.py +307 -0
- package/python/vendor/hkc/hkc_core/utils/__init__.py +0 -0
- package/python/vendor/hkc/hkc_core/utils/id_gen.py +113 -0
- package/python/vendor/hkc/hkc_crystallizer/__init__.py +44 -0
- package/python/vendor/hkc/hkc_crystallizer/adapters.py +94 -0
- package/python/vendor/hkc/hkc_crystallizer/candidate.py +145 -0
- package/python/vendor/hkc/hkc_crystallizer/crystallizer.py +179 -0
- package/python/vendor/hkc/hkc_crystallizer/ingress.py +90 -0
- package/python/vendor/hkc/hkc_kde/__init__.py +0 -0
- package/python/vendor/hkc/hkc_kde/chunker.py +197 -0
- package/python/vendor/hkc/hkc_kde/extractor.py +623 -0
- package/python/vendor/hkc/hkc_kde/kde.py +298 -0
- package/python/vendor/hkc/hkc_kde/loaders/__init__.py +0 -0
- package/python/vendor/hkc/hkc_kde/loaders/ebook_loader.py +153 -0
- package/python/vendor/hkc/hkc_kde/loaders/office_loader.py +194 -0
- package/python/vendor/hkc/hkc_kde/loaders/pdf_loader.py +162 -0
- package/python/vendor/hkc/hkc_kde/loaders/text_loader.py +157 -0
- package/python/vendor/hkc/hkc_kde/loaders/web_loader.py +91 -0
- package/python/vendor/hkc/hkc_kde/models.py +74 -0
- package/python/vendor/hkc/hkc_kde/packager.py +329 -0
- package/python/vendor/hkc/hkc_kde/relation_disc.py +151 -0
- package/python/vendor/hkc/hkc_kee/__init__.py +0 -0
- package/python/vendor/hkc/hkc_kee/dedup.py +227 -0
- package/python/vendor/hkc/hkc_kee/fingerprint.py +106 -0
- package/python/vendor/hkc/hkc_kee/kee.py +541 -0
- package/python/vendor/hkc/hkc_kep/__init__.py +0 -0
- package/python/vendor/hkc/hkc_kep/event_bus.py +205 -0
- package/python/vendor/hkc/hkc_sdk/__init__.py +63 -0
- package/python/vendor/hkc/hkc_sdk/base.py +151 -0
- package/python/vendor/hkc/hkc_sdk/direct_client.py +153 -0
- package/python/vendor/hkc/hkc_sdk/exceptions.py +39 -0
- package/python/vendor/hkc/hkc_sdk/http_client.py +166 -0
- package/python/vendor/hkc/hkc_sdk/models.py +171 -0
- package/python/vendor/hkc/hkc_search/__init__.py +0 -0
- package/python/vendor/hkc/hkc_search/bm25.py +325 -0
- package/python/vendor/hkc/hkc_search/embedding_backends.py +374 -0
- package/python/vendor/hkc/hkc_search/graph_search.py +132 -0
- package/python/vendor/hkc/hkc_search/hybrid.py +331 -0
- package/python/vendor/hkc/hkc_search/index_build_manager.py +378 -0
- package/python/vendor/hkc/hkc_search/vector_search.py +484 -0
- package/python/vendor/hmr/__init__.py +0 -0
- package/python/vendor/hmr/core/__init__.py +0 -0
- package/python/vendor/hmr/core/hmr.py +684 -0
- package/python/vendor/hmr/core/models.py +310 -0
- package/python/vendor/hmr/engines/__init__.py +0 -0
- package/python/vendor/hmr/engines/evolution.py +710 -0
- package/python/vendor/hmr/engines/jit_compiler.py +472 -0
- package/python/vendor/hmr/engines/lifecycle.py +264 -0
- package/python/vendor/hmr/engines/policy.py +625 -0
- package/python/vendor/hmr/engines/recall.py +260 -0
- package/python/vendor/hmr/engines/runtime_state.py +158 -0
- package/python/vendor/hmr/engines/scheduler.py +323 -0
- package/python/vendor/hmr/engines/semantic.py +150 -0
- package/python/vendor/hmr/engines/temporal.py +261 -0
- package/python/vendor/hmr/engines/thought_chain.py +635 -0
- package/python/vendor/hmr/graph/__init__.py +0 -0
- package/python/vendor/hmr/graph/cwg.py +338 -0
- package/python/vendor/hmr/graph/memory_graph.py +530 -0
- package/python/vendor/hmr/storage/__init__.py +0 -0
- package/python/vendor/hmr/storage/memory_fs.py +300 -0
- package/python/vendor/hmr/storage/vector_store.py +520 -0
|
@@ -0,0 +1,292 @@
|
|
|
1
|
+
<script setup>
|
|
2
|
+
import { computed, onMounted, ref } from 'vue'
|
|
3
|
+
import PanelBox from './PanelBox.vue'
|
|
4
|
+
import {
|
|
5
|
+
panels, loadPanel, refreshPanel, startReview, revealCard, gradeCard, openKu,
|
|
6
|
+
} from '../../stores/panels.js'
|
|
7
|
+
|
|
8
|
+
const rv = panels.review
|
|
9
|
+
const err = ref('')
|
|
10
|
+
|
|
11
|
+
onMounted(() => loadPanel('review'))
|
|
12
|
+
|
|
13
|
+
const st = computed(() => rv.stats || {})
|
|
14
|
+
const card = computed(() => rv.queue[rv.index] || null)
|
|
15
|
+
const total = computed(() => rv.queue.length)
|
|
16
|
+
const pos = computed(() => Math.min(rv.index + 1, total.value))
|
|
17
|
+
|
|
18
|
+
const masteryPct = computed(() => Math.round((st.value.avg_mastery || 0) * 100))
|
|
19
|
+
const todo = computed(() => (st.value.due || 0) + (st.value.fresh || 0))
|
|
20
|
+
|
|
21
|
+
const W = 620
|
|
22
|
+
const H = 130
|
|
23
|
+
const DAYS = 30
|
|
24
|
+
|
|
25
|
+
const curve = computed(() => {
|
|
26
|
+
const c = card.value
|
|
27
|
+
const interval = c?.interval || 0
|
|
28
|
+
const ef = c?.ease_factor || 2.5
|
|
29
|
+
const S = interval > 0 ? 9.49 * interval * (ef / 2.5) : 1.2
|
|
30
|
+
|
|
31
|
+
const pts = []
|
|
32
|
+
for (let d = 0; d <= DAYS; d += 0.5) {
|
|
33
|
+
const r = Math.exp(-d / S)
|
|
34
|
+
pts.push(`${((d / DAYS) * W).toFixed(1)},${(H - r * H).toFixed(1)}`)
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
const dueDay = c?.days_until_due ?? 0
|
|
38
|
+
const showDot = interval > 0 && dueDay <= DAYS
|
|
39
|
+
return {
|
|
40
|
+
path: `M${pts.join(' L')}`,
|
|
41
|
+
s: S,
|
|
42
|
+
due: showDot
|
|
43
|
+
? { x: (dueDay / DAYS) * W, y: H - Math.exp(-dueDay / S) * H }
|
|
44
|
+
: null,
|
|
45
|
+
now: { x: 0, y: 0 },
|
|
46
|
+
}
|
|
47
|
+
})
|
|
48
|
+
|
|
49
|
+
const dueText = computed(() => {
|
|
50
|
+
const c = card.value
|
|
51
|
+
if (!c || !c.interval) return '新卡:曲线是「不复习就忘」的示意'
|
|
52
|
+
const h = c.due_in_hours || 0
|
|
53
|
+
const when = h <= 0 ? '已到期' : h < 24 ? `${Math.round(h)} 小时后` : `${c.days_until_due} 天后`
|
|
54
|
+
return `S≈${curve.value.s.toFixed(1)} 天 · 下次 ${when}`
|
|
55
|
+
})
|
|
56
|
+
|
|
57
|
+
const load = computed(() => {
|
|
58
|
+
const by = st.value.load7?.by_day || {}
|
|
59
|
+
return Array.from({ length: 7 }, (_, d) => ({ d, n: by[d] ?? by[String(d)] ?? 0 }))
|
|
60
|
+
})
|
|
61
|
+
const loadMax = computed(() => Math.max(1, ...load.value.map((x) => x.n)))
|
|
62
|
+
|
|
63
|
+
async function grade(g) {
|
|
64
|
+
err.value = ''
|
|
65
|
+
try {
|
|
66
|
+
await gradeCard(g)
|
|
67
|
+
} catch (e) {
|
|
68
|
+
err.value = String(e?.message || e)
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
</script>
|
|
72
|
+
|
|
73
|
+
<template>
|
|
74
|
+
<PanelBox
|
|
75
|
+
title="复习"
|
|
76
|
+
tag="SM-2"
|
|
77
|
+
:state="rv.state"
|
|
78
|
+
:ready="rv.state === 'ok'"
|
|
79
|
+
@refresh="refreshPanel('review')"
|
|
80
|
+
>
|
|
81
|
+
<div class="pn-kpi">
|
|
82
|
+
<div><b>{{ st.cards }}</b><span>复习卡</span></div>
|
|
83
|
+
<div><b>{{ st.due }}</b><span>今日到期</span></div>
|
|
84
|
+
<div><b>{{ st.fresh }}</b><span>新卡</span></div>
|
|
85
|
+
<div><b>{{ masteryPct }}%</b><span>平均掌握</span></div>
|
|
86
|
+
</div>
|
|
87
|
+
|
|
88
|
+
<div class="rv-grid">
|
|
89
|
+
<section>
|
|
90
|
+
<div class="pn-h">
|
|
91
|
+
学习卡
|
|
92
|
+
<em v-if="rv.session === 'running'">{{ pos }} / {{ total }}</em>
|
|
93
|
+
<em v-else>队列 {{ total }} 张</em>
|
|
94
|
+
</div>
|
|
95
|
+
|
|
96
|
+
<div v-if="rv.session === 'running' && card" class="card">
|
|
97
|
+
<div class="ct">
|
|
98
|
+
<span class="pn-tag">{{ card.ku_type }}</span>
|
|
99
|
+
<span class="dim">{{ card.domain || '未分域' }}</span>
|
|
100
|
+
<span v-if="card.is_new" class="pn-tag new">新卡</span>
|
|
101
|
+
<span v-else class="dim">第 {{ (card.repetitions || 0) + 1 }} 次</span>
|
|
102
|
+
</div>
|
|
103
|
+
|
|
104
|
+
<h3>{{ card.name }}</h3>
|
|
105
|
+
|
|
106
|
+
<template v-if="rv.revealed">
|
|
107
|
+
<p v-if="card.summary && card.summary !== card.name" class="sum">{{ card.summary }}</p>
|
|
108
|
+
<p v-if="card.text" class="src">{{ card.text }}</p>
|
|
109
|
+
<div class="grades">
|
|
110
|
+
<button class="g g0" @click="grade(0)">忘记<span>重新开始</span></button>
|
|
111
|
+
<button class="g g3" @click="grade(3)">模糊<span>间隔不涨</span></button>
|
|
112
|
+
<button class="g g4" @click="grade(4)">记得<span>正常推进</span></button>
|
|
113
|
+
<button class="g g5" @click="grade(5)">轻松<span>EF +0.1</span></button>
|
|
114
|
+
</div>
|
|
115
|
+
</template>
|
|
116
|
+
<template v-else>
|
|
117
|
+
<p class="hint">先在心里回想一遍,再显示答案。凭印象评分,不要凭「刚才看过」。</p>
|
|
118
|
+
<button class="act" @click="revealCard()">显示答案</button>
|
|
119
|
+
</template>
|
|
120
|
+
<p v-if="err" class="err">{{ err }}</p>
|
|
121
|
+
</div>
|
|
122
|
+
|
|
123
|
+
<div v-else-if="rv.session === 'done'" class="done">
|
|
124
|
+
<b>这一轮过完了</b>
|
|
125
|
+
<p v-if="rv.lastMsg">{{ rv.lastMsg }}</p>
|
|
126
|
+
<p class="dim">下一轮按 SM-2 排期,到期的会重新出现在这里。</p>
|
|
127
|
+
<button class="act" @click="startReview()">再来一轮</button>
|
|
128
|
+
</div>
|
|
129
|
+
|
|
130
|
+
<div v-else class="idle">
|
|
131
|
+
<p v-if="todo">
|
|
132
|
+
今日待办:<b>{{ st.due }}</b> 张到期 + <b>{{ st.fresh }}</b> 张新卡
|
|
133
|
+
</p>
|
|
134
|
+
<p v-else-if="!st.cards" class="dim">
|
|
135
|
+
还没有复习卡。在右栏上部或学习库录一句知识,抽取出的知识单元会自动变成卡。
|
|
136
|
+
</p>
|
|
137
|
+
<p v-else class="dim">今天的卡都过完了。明天再来,间隔会按 SM-2 自然拉长。</p>
|
|
138
|
+
<button v-if="todo" class="act" @click="startReview()">
|
|
139
|
+
开始复习 {{ Math.min(todo, 20) }} 张
|
|
140
|
+
</button>
|
|
141
|
+
</div>
|
|
142
|
+
</section>
|
|
143
|
+
|
|
144
|
+
<aside class="side">
|
|
145
|
+
<div class="pn-h">遗忘曲线 <em>R = e^(−t/S)</em></div>
|
|
146
|
+
<svg class="curve" :viewBox="`0 0 ${W} ${H}`" preserveAspectRatio="none">
|
|
147
|
+
<line class="ref" x1="0" :y1="H * 0.1" :x2="W" :y2="H * 0.1" />
|
|
148
|
+
<path class="line" :d="curve.path" />
|
|
149
|
+
<circle v-if="curve.due" class="dot" :cx="curve.due.x" :cy="curve.due.y" r="4" />
|
|
150
|
+
</svg>
|
|
151
|
+
<div class="axis">
|
|
152
|
+
<span>今天</span>
|
|
153
|
+
<span class="dim">{{ dueText }}</span>
|
|
154
|
+
<span>+{{ DAYS }} 天</span>
|
|
155
|
+
</div>
|
|
156
|
+
<p class="note">
|
|
157
|
+
排期规则:答「忘记」重置为 1 天;答「记得 / 轻松」按 1 → 6 → 16 天递进,
|
|
158
|
+
EF 每次 ±0.1 微调,间隔随熟练度拉长。
|
|
159
|
+
</p>
|
|
160
|
+
<p class="note warn">
|
|
161
|
+
进度存在知识单元自身,和知识星球共用同一个库。所以在星球里「按来源删除」删掉的
|
|
162
|
+
卡片,进度会一起消失;清库接口会清空全部知识与进度。
|
|
163
|
+
</p>
|
|
164
|
+
|
|
165
|
+
<div class="pn-h" style="margin-top: 16px">
|
|
166
|
+
未来 7 天 <em>{{ st.load7?.total_due || 0 }} 张</em>
|
|
167
|
+
</div>
|
|
168
|
+
<div class="load">
|
|
169
|
+
<div v-for="x in load" :key="x.d" class="bar">
|
|
170
|
+
<i :style="{ height: `${Math.max(2, (x.n / loadMax) * 34)}px` }" :class="{ zero: !x.n }" />
|
|
171
|
+
<span>{{ x.d === 0 ? '今' : `+${x.d}` }}</span>
|
|
172
|
+
<em>{{ x.n }}</em>
|
|
173
|
+
</div>
|
|
174
|
+
</div>
|
|
175
|
+
|
|
176
|
+
<template v-if="st.risk?.length">
|
|
177
|
+
<div class="pn-h" style="margin-top: 16px">遗忘风险</div>
|
|
178
|
+
<button
|
|
179
|
+
v-for="r in st.risk"
|
|
180
|
+
:key="r.item_id"
|
|
181
|
+
class="pn-row clickable"
|
|
182
|
+
@click="openKu(r.item_id)"
|
|
183
|
+
>
|
|
184
|
+
<span class="m">
|
|
185
|
+
<b>{{ r.name || r.item_id }}</b>
|
|
186
|
+
<span class="s">{{ r.reason }}</span>
|
|
187
|
+
</span>
|
|
188
|
+
</button>
|
|
189
|
+
</template>
|
|
190
|
+
</aside>
|
|
191
|
+
</div>
|
|
192
|
+
</PanelBox>
|
|
193
|
+
</template>
|
|
194
|
+
|
|
195
|
+
<style scoped>
|
|
196
|
+
.rv-grid {
|
|
197
|
+
display: grid;
|
|
198
|
+
grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
|
|
199
|
+
gap: 22px;
|
|
200
|
+
align-items: start;
|
|
201
|
+
}
|
|
202
|
+
@container (max-width: 820px) {
|
|
203
|
+
.rv-grid { grid-template-columns: minmax(0, 1fr); gap: 20px; }
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
.card {
|
|
207
|
+
padding: 16px 18px 18px;
|
|
208
|
+
border-radius: var(--r-md);
|
|
209
|
+
background: rgba(255, 255, 255, 0.86);
|
|
210
|
+
border: 1px solid var(--line-soft);
|
|
211
|
+
box-shadow: 0 1px 3px rgba(23, 32, 26, 0.04);
|
|
212
|
+
}
|
|
213
|
+
.ct { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
|
|
214
|
+
.ct .dim { font-size: 11.5px; color: var(--dim); }
|
|
215
|
+
.pn-tag.new { background: rgba(26, 157, 95, 0.12); color: var(--green); }
|
|
216
|
+
.card h3 {
|
|
217
|
+
font-family: var(--serif);
|
|
218
|
+
font-size: 17px; line-height: 1.62; font-weight: 600;
|
|
219
|
+
color: var(--ink); margin-bottom: 12px;
|
|
220
|
+
}
|
|
221
|
+
.sum { font-size: 13px; line-height: 1.8; color: var(--dim); margin-bottom: 10px; }
|
|
222
|
+
.src {
|
|
223
|
+
font-size: 12px; line-height: 1.85; color: var(--dim);
|
|
224
|
+
padding: 9px 12px; border-left: 2px solid var(--line);
|
|
225
|
+
background: rgba(23, 32, 26, 0.025);
|
|
226
|
+
margin-bottom: 14px; white-space: pre-wrap;
|
|
227
|
+
}
|
|
228
|
+
.hint { font-size: 12px; color: var(--dim); margin: 4px 0 14px; line-height: 1.7; }
|
|
229
|
+
.err { margin-top: 10px; font-size: 11px; color: #b4453c; }
|
|
230
|
+
|
|
231
|
+
.act {
|
|
232
|
+
display: inline-block;
|
|
233
|
+
padding: 8px 18px; border-radius: var(--r-pill);
|
|
234
|
+
font-size: 12px; font-weight: 600; color: #fff;
|
|
235
|
+
background: var(--green);
|
|
236
|
+
transition: opacity 0.15s;
|
|
237
|
+
}
|
|
238
|
+
.act:hover { opacity: 0.9; }
|
|
239
|
+
|
|
240
|
+
.grades { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 7px; }
|
|
241
|
+
.g {
|
|
242
|
+
display: flex; flex-direction: column; align-items: center; gap: 2px;
|
|
243
|
+
padding: 9px 4px 8px; border-radius: var(--r-sm);
|
|
244
|
+
font-size: 12px; font-weight: 600; color: var(--ink);
|
|
245
|
+
background: rgba(255, 255, 255, 0.9);
|
|
246
|
+
border: 1px solid var(--line-soft);
|
|
247
|
+
transition: border-color 0.14s, background 0.14s, color 0.14s;
|
|
248
|
+
}
|
|
249
|
+
.g span { font-size: 11px; font-weight: 500; color: var(--dim); }
|
|
250
|
+
.g:hover { border-color: rgba(26, 157, 95, 0.42); background: rgba(26, 157, 95, 0.06); }
|
|
251
|
+
.g0:hover { border-color: rgba(180, 69, 60, 0.42); background: rgba(180, 69, 60, 0.06); }
|
|
252
|
+
|
|
253
|
+
.done, .idle { padding: 14px 2px; }
|
|
254
|
+
.done b { font-size: 13px; }
|
|
255
|
+
.done p, .idle p { font-size: 12px; line-height: 1.8; color: var(--dim); margin: 6px 0 14px; }
|
|
256
|
+
.idle b { color: var(--ink); }
|
|
257
|
+
|
|
258
|
+
.curve {
|
|
259
|
+
display: block; width: 100%; height: 130px;
|
|
260
|
+
overflow: visible;
|
|
261
|
+
}
|
|
262
|
+
.curve .ref { stroke: rgba(23, 32, 26, 0.12); stroke-width: 1; stroke-dasharray: 3 3; vector-effect: non-scaling-stroke; }
|
|
263
|
+
.curve .line { fill: none; stroke: var(--green); stroke-width: 1.8; vector-effect: non-scaling-stroke; }
|
|
264
|
+
.curve .dot { fill: var(--green); stroke: #fff; stroke-width: 1.5; vector-effect: non-scaling-stroke; }
|
|
265
|
+
.axis {
|
|
266
|
+
display: flex; justify-content: space-between; align-items: baseline;
|
|
267
|
+
margin-top: 5px; font-size: 11px; font-weight: 600; color: var(--dim);
|
|
268
|
+
}
|
|
269
|
+
.axis .dim { font-family: var(--mono); font-size: 11px; }
|
|
270
|
+
.note {
|
|
271
|
+
margin-top: 8px; font-size: 11.5px; line-height: 1.75; color: var(--dim);
|
|
272
|
+
}
|
|
273
|
+
.note.warn {
|
|
274
|
+
padding: 7px 9px; border-radius: var(--r-sm);
|
|
275
|
+
background: rgba(196, 138, 26, 0.07);
|
|
276
|
+
border-left: 2px solid rgba(196, 138, 26, 0.45);
|
|
277
|
+
color: #8a6a24;
|
|
278
|
+
}
|
|
279
|
+
|
|
280
|
+
.load { display: flex; align-items: flex-end; gap: 6px; padding: 8px 2px 0; }
|
|
281
|
+
.load .bar {
|
|
282
|
+
flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px;
|
|
283
|
+
min-width: 0;
|
|
284
|
+
}
|
|
285
|
+
.load i {
|
|
286
|
+
display: block; width: 100%; max-width: 26px; border-radius: 2px 2px 0 0;
|
|
287
|
+
background: rgba(26, 157, 95, 0.55);
|
|
288
|
+
}
|
|
289
|
+
.load i.zero { background: rgba(23, 32, 26, 0.14); }
|
|
290
|
+
.load span { font-size: 10.5px; color: var(--dim); }
|
|
291
|
+
.load em { font-style: normal; font-family: var(--mono); font-size: 10.5px; font-weight: 600; color: var(--ink); }
|
|
292
|
+
</style>
|
|
@@ -0,0 +1,358 @@
|
|
|
1
|
+
<script setup>
|
|
2
|
+
import { computed, onMounted, ref } from 'vue'
|
|
3
|
+
import PanelBox from './PanelBox.vue'
|
|
4
|
+
import { getJSON } from '../../api.js'
|
|
5
|
+
import { currentLabel, loadModels, modelOptions, selectModel } from '../../stores/model.js'
|
|
6
|
+
import { setModule } from '../../stores/app.js'
|
|
7
|
+
import { setMode, chat, say } from '../../stores/chat.js'
|
|
8
|
+
import { profile, loadProfile, saveNickname } from '../../stores/profile.js'
|
|
9
|
+
import { loadSystemInfo, system } from '../../stores/system.js'
|
|
10
|
+
import { i18n, LOCALES, setLocale, t } from '../../lib/i18n.js'
|
|
11
|
+
|
|
12
|
+
const info = typeof __APP_INFO__ === 'undefined' ? null : __APP_INFO__
|
|
13
|
+
const sha = info?.git?.sha || 'dev'
|
|
14
|
+
const age = computed(() => {
|
|
15
|
+
const ts = info?.git?.ts || 0
|
|
16
|
+
if (!ts) return t('settings.buildLocal')
|
|
17
|
+
const d = Math.floor((Date.now() - ts) / 86400000)
|
|
18
|
+
return d <= 0 ? t('settings.buildToday') : t('settings.buildDays', { n: d })
|
|
19
|
+
})
|
|
20
|
+
|
|
21
|
+
const open = ref('') // '' | 'model' | 'keys' —— 一次只展开一组,行数不会失控
|
|
22
|
+
const up = ref(null) // null=探测中 | true | false
|
|
23
|
+
const err = ref('')
|
|
24
|
+
|
|
25
|
+
const cur = computed(() => currentLabel())
|
|
26
|
+
const options = computed(() => modelOptions())
|
|
27
|
+
|
|
28
|
+
const KEYS = computed(() => [
|
|
29
|
+
['Enter', t('key.enter')],
|
|
30
|
+
['Shift + Enter', t('key.shiftEnter')],
|
|
31
|
+
['/', t('key.slash')],
|
|
32
|
+
['@', t('key.at')],
|
|
33
|
+
['↑ ↓', t('key.arrows')],
|
|
34
|
+
['Esc', t('key.esc')],
|
|
35
|
+
['Ctrl + ,', t('key.ctrlComma')],
|
|
36
|
+
])
|
|
37
|
+
|
|
38
|
+
const nickDraft = ref('')
|
|
39
|
+
|
|
40
|
+
onMounted(() => {
|
|
41
|
+
loadModels()
|
|
42
|
+
loadSystemInfo()
|
|
43
|
+
loadProfile().then(() => { nickDraft.value = profile.nickname })
|
|
44
|
+
probe()
|
|
45
|
+
})
|
|
46
|
+
|
|
47
|
+
async function saveNick() {
|
|
48
|
+
try {
|
|
49
|
+
await saveNickname(nickDraft.value)
|
|
50
|
+
say(profile.nickname ? t('settings.saidNick', { name: profile.nickname }) : t('settings.saidNickCleared'))
|
|
51
|
+
open.value = ''
|
|
52
|
+
} catch (e) {
|
|
53
|
+
say(t('settings.errSaveNick', { msg: e.message }), 4000)
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
function pickLang(id) {
|
|
58
|
+
setLocale(id)
|
|
59
|
+
const name = LOCALES.find((l) => l.id === id)?.label || id
|
|
60
|
+
say(t('settings.saidLang', { name }))
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
const upd = computed(() => system.update || null)
|
|
64
|
+
const updLabel = computed(() => {
|
|
65
|
+
const u = upd.value
|
|
66
|
+
if (!u) return '…'
|
|
67
|
+
if (!u.enabled) return t('settings.updNotEnabled')
|
|
68
|
+
if (u.update_available) return t('settings.updAvailable', { v: u.latest })
|
|
69
|
+
if (u.latest) return t('settings.updLatest')
|
|
70
|
+
return u.error ? t('settings.updFailed') : t('settings.updPending')
|
|
71
|
+
})
|
|
72
|
+
const updHint = computed(() => {
|
|
73
|
+
const u = upd.value
|
|
74
|
+
if (!u) return t('common.loading')
|
|
75
|
+
if (!u.enabled) return t('settings.updHintOff')
|
|
76
|
+
if (u.error) return t('settings.updHintError', { msg: u.error })
|
|
77
|
+
if (u.update_available) return t('settings.updHintNew', { cur: u.current, latest: u.latest })
|
|
78
|
+
return t('settings.updHintOk', { cur: u.current })
|
|
79
|
+
})
|
|
80
|
+
|
|
81
|
+
async function probe() {
|
|
82
|
+
up.value = null
|
|
83
|
+
try {
|
|
84
|
+
await getJSON('/status')
|
|
85
|
+
up.value = true
|
|
86
|
+
} catch {
|
|
87
|
+
up.value = false
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
async function refresh() {
|
|
92
|
+
await loadModels(true).catch(() => {})
|
|
93
|
+
loadSystemInfo(true) // 更新状态也刷一次(后端 24h 缓存内不会真的外呼)
|
|
94
|
+
probe()
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
async function pick(o) {
|
|
98
|
+
try {
|
|
99
|
+
await selectModel({
|
|
100
|
+
source: o.source,
|
|
101
|
+
provider: o.source === 'preset' ? o.key : null,
|
|
102
|
+
name: o.source === 'custom' ? o.key : null,
|
|
103
|
+
})
|
|
104
|
+
open.value = ''
|
|
105
|
+
say(t('settings.saidSwitched', { label: o.label }))
|
|
106
|
+
} catch (e) {
|
|
107
|
+
err.value = e.message
|
|
108
|
+
say(t('settings.errSwitch', { msg: e.message }), 4000)
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
function mode(m) {
|
|
113
|
+
setMode(m)
|
|
114
|
+
say(m === 'stream' ? t('settings.saidStream') : t('settings.saidOrchestrate'))
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
const ICONS = {
|
|
118
|
+
gear: ['M12 9.2a2.8 2.8 0 1 0 0 5.6 2.8 2.8 0 0 0 0-5.6z', 'M12 3.2v2.2', 'M12 18.6v2.2', 'M3.2 12h2.2', 'M18.6 12h2.2', 'M5.8 5.8l1.6 1.6', 'M16.6 16.6l1.6 1.6', 'M18.2 5.8l-1.6 1.6', 'M7.4 16.6l-1.6 1.6'],
|
|
119
|
+
gauge: ['M3.6 15.6a8.4 8.4 0 1 1 16.8 0', 'M12 15.6l4.2-4.8'],
|
|
120
|
+
chat: ['M19.6 14.8a1.8 1.8 0 0 1-1.8 1.8H8.6L5 20v-3.4H6.2A1.8 1.8 0 0 1 4.4 14.8V6.4A1.8 1.8 0 0 1 6.2 4.6h11.6a1.8 1.8 0 0 1 1.8 1.8z'],
|
|
121
|
+
keys: ['M3.8 8.2h16.4v7.6H3.8z', 'M7 11h.01', 'M11 11h.01', 'M15 11h.01', 'M9 13.8h6'],
|
|
122
|
+
server: ['M4.4 5.4h15.2v4.8H4.4z', 'M4.4 13.8h15.2v4.8H4.4z', 'M7.4 7.8h.01', 'M7.4 16.2h.01'],
|
|
123
|
+
globe: ['M12 3.4a8.6 8.6 0 1 0 0 17.2 8.6 8.6 0 0 0 0-17.2z', 'M3.6 12h16.8', 'M12 3.4c2.2 2.4 3.4 5.4 3.4 8.6s-1.2 6.2-3.4 8.6c-2.2-2.4-3.4-5.4-3.4-8.6s1.2-6.2 3.4-8.6z'],
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
const icon = (n) => ICONS[n] || ICONS.gear
|
|
127
|
+
</script>
|
|
128
|
+
|
|
129
|
+
<template>
|
|
130
|
+
<PanelBox :title="t('settings.title')" tag="Settings" state="idle" :ready="true" @refresh="refresh">
|
|
131
|
+
<div class="card">
|
|
132
|
+
<div class="grp">{{ t('settings.groupModel') }}</div>
|
|
133
|
+
|
|
134
|
+
<button class="row" :aria-expanded="open === 'model'" @click="open = open === 'model' ? '' : 'model'">
|
|
135
|
+
<span class="ic"><svg viewBox="0 0 24 24"><path v-for="(d, i) in icon('gear')" :key="i" :d="d" /></svg></span>
|
|
136
|
+
<span class="m"><b>{{ t('settings.modelProvider') }}</b><span>{{ t('settings.modelProviderSub') }}</span></span>
|
|
137
|
+
<span class="hint"><i class="dot" :style="{ background: cur.color }" />{{ cur.name }}</span>
|
|
138
|
+
<span class="chev" :class="{ open: open === 'model' }">›</span>
|
|
139
|
+
</button>
|
|
140
|
+
|
|
141
|
+
<div v-if="open === 'model'" class="sub">
|
|
142
|
+
<button
|
|
143
|
+
v-for="o in options"
|
|
144
|
+
:key="`${o.source}-${o.key}`"
|
|
145
|
+
class="opt"
|
|
146
|
+
:class="{ on: o.active }"
|
|
147
|
+
@click="pick(o)"
|
|
148
|
+
>
|
|
149
|
+
<span class="dot" :style="{ background: o.color }" />
|
|
150
|
+
<span class="m"><b>{{ o.label }}</b><span>{{ o.sub }}</span></span>
|
|
151
|
+
<span v-if="o.active" class="pn-tag green">{{ t('settings.current') }}</span>
|
|
152
|
+
<span v-else-if="o.configured === false" class="pn-tag amber">{{ t('settings.unconfigured') }}</span>
|
|
153
|
+
</button>
|
|
154
|
+
<p class="tip">
|
|
155
|
+
{{ t('settings.providerNote') }}
|
|
156
|
+
</p>
|
|
157
|
+
<p v-if="err" class="tip err">{{ err }}</p>
|
|
158
|
+
</div>
|
|
159
|
+
|
|
160
|
+
<button class="row" @click="setModule('usage')">
|
|
161
|
+
<span class="ic"><svg viewBox="0 0 24 24"><path v-for="(d, i) in icon('gauge')" :key="i" :d="d" /></svg></span>
|
|
162
|
+
<span class="m"><b>{{ t('settings.usage') }}</b><span>{{ t('settings.usageSub') }}</span></span>
|
|
163
|
+
<span class="chev">›</span>
|
|
164
|
+
</button>
|
|
165
|
+
</div>
|
|
166
|
+
|
|
167
|
+
<div class="card">
|
|
168
|
+
<div class="grp">{{ t('settings.groupChat') }}</div>
|
|
169
|
+
|
|
170
|
+
<div class="row static">
|
|
171
|
+
<span class="ic"><svg viewBox="0 0 24 24"><path v-for="(d, i) in icon('chat')" :key="i" :d="d" /></svg></span>
|
|
172
|
+
<span class="m"><b>{{ t('settings.mode') }}</b><span>{{ t('settings.modeSub') }}</span></span>
|
|
173
|
+
<span class="seg">
|
|
174
|
+
<button :class="{ on: chat.mode === 'stream' }" @click="mode('stream')">{{ t('settings.stream') }}</button>
|
|
175
|
+
<button :class="{ on: chat.mode === 'orchestrate' }" @click="mode('orchestrate')">{{ t('settings.orchestrate') }}</button>
|
|
176
|
+
</span>
|
|
177
|
+
</div>
|
|
178
|
+
|
|
179
|
+
<button class="row" :aria-expanded="open === 'nick'" @click="open = open === 'nick' ? '' : 'nick'">
|
|
180
|
+
<span class="ic"><svg viewBox="0 0 24 24"><path v-for="(d, i) in icon('chat')" :key="i" :d="d" /></svg></span>
|
|
181
|
+
<span class="m"><b>{{ t('settings.nickname') }}</b><span>{{ t('settings.nicknameSub') }}</span></span>
|
|
182
|
+
<span class="hint">{{ profile.nickname || t('common.notSet') }}</span>
|
|
183
|
+
<span class="chev" :class="{ open: open === 'nick' }">›</span>
|
|
184
|
+
</button>
|
|
185
|
+
|
|
186
|
+
<div v-if="open === 'nick'" class="sub">
|
|
187
|
+
<div class="nick-edit">
|
|
188
|
+
<input
|
|
189
|
+
v-model="nickDraft"
|
|
190
|
+
class="nick-in"
|
|
191
|
+
maxlength="24"
|
|
192
|
+
:placeholder="t('settings.nicknamePh')"
|
|
193
|
+
@keydown.enter.prevent="saveNick"
|
|
194
|
+
/>
|
|
195
|
+
<button class="nick-save" :disabled="profile.saving" @click="saveNick">{{ t('common.save') }}</button>
|
|
196
|
+
</div>
|
|
197
|
+
<p class="tip">{{ t('settings.nicknameNote') }}</p>
|
|
198
|
+
</div>
|
|
199
|
+
|
|
200
|
+
<button class="row" :aria-expanded="open === 'keys'" @click="open = open === 'keys' ? '' : 'keys'">
|
|
201
|
+
<span class="ic"><svg viewBox="0 0 24 24"><path v-for="(d, i) in icon('keys')" :key="i" :d="d" /></svg></span>
|
|
202
|
+
<span class="m"><b>{{ t('settings.shortcuts') }}</b><span>{{ t('settings.shortcutsSub') }}</span></span>
|
|
203
|
+
<span class="hint">{{ t('common.count', { n: KEYS.length }) }}</span>
|
|
204
|
+
<span class="chev" :class="{ open: open === 'keys' }">›</span>
|
|
205
|
+
</button>
|
|
206
|
+
|
|
207
|
+
<div v-if="open === 'keys'" class="sub">
|
|
208
|
+
<div v-for="k in KEYS" :key="k[0]" class="kv">
|
|
209
|
+
<kbd>{{ k[0] }}</kbd>
|
|
210
|
+
<span>{{ k[1] }}</span>
|
|
211
|
+
</div>
|
|
212
|
+
</div>
|
|
213
|
+
</div>
|
|
214
|
+
|
|
215
|
+
<div class="card">
|
|
216
|
+
<div class="grp">{{ t('settings.groupUi') }}</div>
|
|
217
|
+
|
|
218
|
+
<div class="row static">
|
|
219
|
+
<span class="ic"><svg viewBox="0 0 24 24"><path v-for="(d, i) in icon('globe')" :key="i" :d="d" /></svg></span>
|
|
220
|
+
<span class="m"><b>{{ t('settings.language') }}</b><span>{{ t('settings.languageSub') }}</span></span>
|
|
221
|
+
<span class="seg">
|
|
222
|
+
<button
|
|
223
|
+
v-for="l in LOCALES"
|
|
224
|
+
:key="l.id"
|
|
225
|
+
:class="{ on: i18n.locale === l.id }"
|
|
226
|
+
@click="pickLang(l.id)"
|
|
227
|
+
>{{ l.label }}</button>
|
|
228
|
+
</span>
|
|
229
|
+
</div>
|
|
230
|
+
|
|
231
|
+
<p class="tip">{{ t('settings.languageNote') }}</p>
|
|
232
|
+
</div>
|
|
233
|
+
|
|
234
|
+
<div class="card">
|
|
235
|
+
<div class="grp">{{ t('settings.groupSystem') }}</div>
|
|
236
|
+
|
|
237
|
+
<button class="row" :title="up ? t('settings.reprobe') : t('settings.retry')" @click="probe">
|
|
238
|
+
<span class="ic"><svg viewBox="0 0 24 24"><path v-for="(d, i) in icon('server')" :key="i" :d="d" /></svg></span>
|
|
239
|
+
<span class="m">
|
|
240
|
+
<b>{{ t('settings.backend') }}</b>
|
|
241
|
+
<span>/api · {{ up === null ? t('settings.probing') : up ? t('common.online') : t('common.offlineShort') }}</span>
|
|
242
|
+
</span>
|
|
243
|
+
<span class="pn-tag" :class="up ? 'green' : up === false ? 'amber' : ''">
|
|
244
|
+
{{ up === null ? '…' : up ? t('settings.ok') : t('settings.retry') }}
|
|
245
|
+
</span>
|
|
246
|
+
</button>
|
|
247
|
+
|
|
248
|
+
<div class="row static">
|
|
249
|
+
<span class="ic"><svg viewBox="0 0 24 24"><path v-for="(d, i) in icon('gauge')" :key="i" :d="d" /></svg></span>
|
|
250
|
+
<span class="m"><b>{{ t('settings.updates') }}</b><span>{{ updHint }}</span></span>
|
|
251
|
+
<span class="pn-tag" :class="upd?.update_available ? 'amber' : ''">{{ updLabel }}</span>
|
|
252
|
+
</div>
|
|
253
|
+
</div>
|
|
254
|
+
|
|
255
|
+
<div class="foot">
|
|
256
|
+
<span class="mono">git@{{ sha }} · {{ age }}</span>
|
|
257
|
+
<span class="dev" :title="t('settings.buildLocal')">▭</span>
|
|
258
|
+
</div>
|
|
259
|
+
</PanelBox>
|
|
260
|
+
</template>
|
|
261
|
+
|
|
262
|
+
<style scoped>
|
|
263
|
+
.card {
|
|
264
|
+
border-radius: var(--r-mid);
|
|
265
|
+
background: rgba(255, 255, 255, 0.82);
|
|
266
|
+
border: 1px solid var(--line-soft);
|
|
267
|
+
box-shadow: 0 1px 2px rgba(23, 32, 26, 0.04);
|
|
268
|
+
padding: 4px 6px 6px;
|
|
269
|
+
margin-bottom: 12px;
|
|
270
|
+
}
|
|
271
|
+
.grp {
|
|
272
|
+
padding: 8px 8px 6px;
|
|
273
|
+
font-size: 11px; font-weight: 700; letter-spacing: 0.08em;
|
|
274
|
+
color: var(--dim); text-transform: uppercase;
|
|
275
|
+
}
|
|
276
|
+
|
|
277
|
+
.row {
|
|
278
|
+
width: 100%;
|
|
279
|
+
display: flex; align-items: center; gap: 10px;
|
|
280
|
+
padding: 8px; border-radius: var(--r-sm);
|
|
281
|
+
text-align: left;
|
|
282
|
+
transition: background 0.14s;
|
|
283
|
+
}
|
|
284
|
+
.row:hover { background: rgba(255, 255, 255, 0.9); }
|
|
285
|
+
.row.static:hover { background: transparent; }
|
|
286
|
+
.row .ic { width: 22px; height: 22px; display: grid; place-items: center; color: var(--dim); flex-shrink: 0; }
|
|
287
|
+
.row .ic svg {
|
|
288
|
+
width: 16px; height: 16px;
|
|
289
|
+
fill: none; stroke: currentColor; stroke-width: 1.6;
|
|
290
|
+
stroke-linecap: round; stroke-linejoin: round;
|
|
291
|
+
}
|
|
292
|
+
.row .m { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
|
|
293
|
+
.row .m b { font-size: 13px; font-weight: 600; color: var(--ink); }
|
|
294
|
+
.row .m span { font-size: 11.5px; color: var(--dim); }
|
|
295
|
+
.hint { display: flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 600; color: var(--dim); flex-shrink: 0; }
|
|
296
|
+
.hint .dot { width: 7px; height: 7px; border-radius: 50%; }
|
|
297
|
+
.chev { color: var(--dim); font-size: 13px; flex-shrink: 0; transition: transform 0.16s; }
|
|
298
|
+
.chev.open { transform: rotate(90deg); }
|
|
299
|
+
|
|
300
|
+
.seg { display: flex; gap: 2px; padding: 2px; border-radius: var(--r-sm); background: rgba(23, 32, 26, 0.05); flex-shrink: 0; }
|
|
301
|
+
.seg button { padding: 4px 10px; border-radius: 7px; font-size: 11.5px; color: var(--dim); transition: background 0.15s, color 0.15s; }
|
|
302
|
+
.seg button.on { background: #fff; color: var(--ink); font-weight: 600; box-shadow: 0 1px 2px rgba(23, 32, 26, 0.07); }
|
|
303
|
+
|
|
304
|
+
.sub {
|
|
305
|
+
margin: 2px 8px 6px 40px;
|
|
306
|
+
padding: 4px;
|
|
307
|
+
border-left: 1px solid var(--line-soft);
|
|
308
|
+
}
|
|
309
|
+
.opt {
|
|
310
|
+
width: 100%;
|
|
311
|
+
display: flex; align-items: center; gap: 8px;
|
|
312
|
+
padding: 6px 8px; border-radius: 7px;
|
|
313
|
+
text-align: left;
|
|
314
|
+
transition: background 0.13s;
|
|
315
|
+
}
|
|
316
|
+
.opt:hover { background: rgba(255, 255, 255, 0.9); }
|
|
317
|
+
.opt.on { background: rgba(26, 157, 95, 0.09); }
|
|
318
|
+
.opt .dot { width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0; }
|
|
319
|
+
.opt .m { flex: 1; min-width: 0; display: flex; align-items: baseline; gap: 7px; }
|
|
320
|
+
.opt .m b { font-size: 12.5px; font-weight: 600; color: var(--ink); }
|
|
321
|
+
.opt .m span { font-size: 11.5px; color: var(--dim); font-family: var(--mono); }
|
|
322
|
+
|
|
323
|
+
.tip { padding: 4px 8px 2px; font-size: 11.5px; line-height: 1.6; color: var(--dim); }
|
|
324
|
+
.tip.err { color: var(--red); }
|
|
325
|
+
|
|
326
|
+
.nick-edit { display: flex; align-items: center; gap: 6px; padding: 4px 8px 2px; }
|
|
327
|
+
.nick-in {
|
|
328
|
+
flex: 1; min-width: 0;
|
|
329
|
+
padding: 5px 8px; border-radius: 7px;
|
|
330
|
+
font-size: 12.5px; color: var(--ink);
|
|
331
|
+
background: #fff; border: 1px solid var(--line);
|
|
332
|
+
}
|
|
333
|
+
.nick-in:focus { outline: none; border-color: rgba(26, 157, 95, 0.5); }
|
|
334
|
+
.nick-save {
|
|
335
|
+
flex-shrink: 0;
|
|
336
|
+
padding: 5px 11px; border-radius: 7px;
|
|
337
|
+
font-size: 12px; font-weight: 600; color: #fff;
|
|
338
|
+
background: var(--green);
|
|
339
|
+
}
|
|
340
|
+
.nick-save:disabled { opacity: 0.45; }
|
|
341
|
+
|
|
342
|
+
.kv { display: flex; align-items: center; gap: 10px; padding: 4px 8px; }
|
|
343
|
+
.kv kbd {
|
|
344
|
+
min-width: 92px; flex-shrink: 0;
|
|
345
|
+
font-family: var(--mono); font-size: 11.5px; font-weight: 600; color: var(--ink);
|
|
346
|
+
padding: 2px 6px; border-radius: 5px;
|
|
347
|
+
background: rgba(23, 32, 26, 0.05);
|
|
348
|
+
}
|
|
349
|
+
.kv span { font-size: 11.5px; color: var(--dim); }
|
|
350
|
+
|
|
351
|
+
.foot {
|
|
352
|
+
display: flex; align-items: center; justify-content: space-between;
|
|
353
|
+
margin-top: 2px; padding: 10px 4px 2px;
|
|
354
|
+
border-top: 1px solid var(--line-soft);
|
|
355
|
+
}
|
|
356
|
+
.foot .mono { font-family: var(--mono); font-size: 11.5px; color: var(--dim); }
|
|
357
|
+
.foot .dev { font-size: 12px; color: var(--faint); }
|
|
358
|
+
</style>
|