Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/cft0808/edict
/ functions
Functions
535 in github.com/cft0808/edict
⨍
Functions
535
◇
Types & classes
85
↳
Endpoints
28
↓ 101 callers
Method
send_json
(self, data, code=200)
dashboard/server.py:2352
↓ 72 callers
Function
now_iso
返回 UTC ISO 8601 时间字符串(末尾 Z)
scripts/utils.py:27
↓ 23 callers
Function
postJ
(url: string, data: unknown)
edict/frontend/src/api.ts:16
↓ 21 callers
Function
atomic_json_update
原子地读取 → 修改 → 写回 JSON 文件。 modifier(data) 应返回修改后的数据。 使用临时文件 + rename 保证写入原子性。
scripts/file_lock.py:79
↓ 20 callers
Function
_append_audit
追加一条审计记录到 data/audit_log.json(原子操作)。
scripts/kanban_update.py:137
↓ 18 callers
Function
atomic_json_write
原子写入 JSON 文件(持排他锁 + tmpfile rename)。 直接写入,不读取现有内容(避免 atomic_json_update 的多余读开销)。
scripts/file_lock.py:118
↓ 17 callers
Function
read_json
安全读取 JSON 文件,失败返回 default
scripts/utils.py:11
↓ 16 callers
Function
_infer_agent_id_from_runtime
尽量推断当前执行该命令的 Agent。
scripts/kanban_update.py:243
↓ 16 callers
Function
_scheduler_add_flow
(task, remark, to='')
dashboard/server.py:1070
↓ 15 callers
Function
load_tasks
()
dashboard/server.py:137
↓ 15 callers
Method
publish
发布事件到 Redis Stream。 Returns: event_id (str): 由 Redis 自动生成的 Stream entry ID
edict/backend/app/services/event_bus.py:73
↓ 13 callers
Function
_ensure_scheduler
(task)
dashboard/server.py:1042
↓ 13 callers
Function
atomic_json_read
持锁读取 JSON 文件。
scripts/file_lock.py:63
↓ 12 callers
Method
close
(self)
edict/backend/app/services/event_bus.py:60
↓ 12 callers
Function
fetchJ
(url: string)
edict/frontend/src/api.ts:10
↓ 12 callers
Method
start
(self)
tests/test_dashboard_dispatch.py:46
↓ 11 callers
Function
_setup_server
Bootstrap server module with isolated data directory.
tests/test_task_mutation_race.py:25
↓ 11 callers
Method
_stream_key
(self, topic: str)
edict/backend/app/services/event_bus.py:70
↓ 11 callers
Function
cmd_create
新建任务(收旨时立即调用)
scripts/kanban_update.py:290
↓ 10 callers
Function
_trigger_refresh
Debounced refresh — touch 信号文件,由独立 watcher 合并执行。 替代原来每次 fork subprocess 的方式,避免多 Agent 并发时产生数百个进程。 如果 refresh_watcher 未运行,会 fallback 到直接 f
scripts/kanban_update.py:113
↓ 10 callers
Function
get_settings
()
edict/backend/app/config.py:82
↓ 9 callers
Function
_get_task
(tid)
tests/test_e2e_kanban.py:27
↓ 9 callers
Function
dispatch_for_state
推进/审批后自动派发对应 Agent(后台异步,不阻塞响应)。
dashboard/server.py:2114
↓ 9 callers
Function
save_tasks
(tasks)
dashboard/server.py:142
↓ 8 callers
Function
_update_task_scheduler
Atomically update a task's scheduler state. Uses ``modify_task`` to hold the file lock for the entire read-modify-write cycle, preventing con
dashboard/server.py:1114
↓ 8 callers
Function
find_task
(tasks, task_id)
scripts/kanban_update.py:190
↓ 8 callers
Function
get_event_bus
()
edict/backend/app/services/event_bus.py:278
↓ 8 callers
Function
python_bin
返回当前 Python 解释器路径,兼容 Windows(无 python3 命令)
scripts/utils.py:43
↓ 7 callers
Function
_api_post
向 Edict API 发送 POST 请求。
edict/scripts/kanban_update_edict.py:124
↓ 7 callers
Function
_check_api
()
edict/scripts/kanban_update_edict.py:166
↓ 7 callers
Function
_fallback_json
降级:导入旧版 kanban_update 逻辑。
edict/scripts/kanban_update_edict.py:177
↓ 7 callers
Method
_validate_url_scheme
(cls, url: str)
edict/backend/app/channels/base.py:25
↓ 7 callers
Function
get
(tag)
scripts/fetch_morning_news.py:82
↓ 6 callers
Method
_extract_domain
(cls, url: str)
edict/backend/app/channels/base.py:29
↓ 6 callers
Function
_infer_agent_id
()
edict/scripts/kanban_update_edict.py:93
↓ 6 callers
Method
create_task
创建任务,事件写入 outbox 表(同一事务原子提交)。
edict/backend/app/services/task_service.py:39
↓ 6 callers
Function
get_task_data_dir
自动选择当前任务数据目录,并缓存结果以保持一次服务期内稳定。
dashboard/server.py:117
↓ 6 callers
Function
safe_name
检查名称是否只含安全字符(字母、数字、下划线、连字符、中文)
scripts/utils.py:37
↓ 5 callers
Method
_get_task
(self, task_id: uuid.UUID)
edict/backend/app/services/task_service.py:294
↓ 5 callers
Method
connect
建立 Redis 连接。
edict/backend/app/services/event_bus.py:50
↓ 5 callers
Function
get_openclaw_home
Return OpenClaw home directory, respecting OPENCLAW_HOME env var.
scripts/utils.py:19
↓ 5 callers
Function
isEdict
(t: Task)
edict/frontend/src/store.ts:60
↓ 5 callers
Function
loadRemoteSkills
()
edict/frontend/src/components/SkillsConfig.tsx:89
↓ 5 callers
Function
pad2
(value: number)
edict/frontend/src/time.ts:1
↓ 5 callers
Function
renderPhase
(title: string, icon: string, items: FlowEntry[])
edict/frontend/src/components/MemorialPanel.tsx:131
↓ 4 callers
Function
_find_by_legacy_id
通过旧版 ID 查找任务(在 tags 或 meta.legacy_id 中搜索)。
edict/backend/app/api/legacy.py:21
↓ 4 callers
Function
_load_pg_transitions
从 task.py 源码解析 STATE_TRANSITIONS(无需 import,避免 SQLAlchemy 依赖)。
tests/test_state_machine_consistency.py:17
↓ 4 callers
Function
_scheduler_mark_progress
(task, note='')
dashboard/server.py:1090
↓ 4 callers
Function
_scheduler_snapshot
(task, note='')
dashboard/server.py:1079
↓ 4 callers
Method
ack
确认消费 — ACK 后事件不会被重新投递。
edict/backend/app/services/event_bus.py:149
↓ 4 callers
Function
cors_headers
(h)
dashboard/server.py:79
↓ 4 callers
Function
deptColor
(d: string)
edict/frontend/src/store.ts:49
↓ 4 callers
Function
doSchedAction
(action: string)
edict/frontend/src/components/TaskModal.tsx:175
↓ 4 callers
Function
formatDashboardTime
( value: number | string | undefined | null, { showSeconds = true }: { showSeconds?: boolean } = {} )
edict/frontend/src/time.ts:36
↓ 4 callers
Function
isArchived
(t: Task)
edict/frontend/src/store.ts:68
↓ 4 callers
Function
normalize_model
(model_value, fallback='unknown')
scripts/sync_agent_config.py:52
↓ 4 callers
Method
org_for_state
(state: TaskState, assignee_org: str | None = None)
edict/backend/app/models/task.py:143
↓ 4 callers
Function
rj
(p, d)
scripts/sync_officials_stats.py:41
↓ 4 callers
Method
to_dict
(self)
edict/backend/app/models/todo.py:50
↓ 3 callers
Function
_check_gateway_alive
检测 Gateway 是否在运行。 Windows 上不要依赖 pgrep;优先通过本地端口探测判断。
dashboard/server.py:812
↓ 3 callers
Function
_load_skill_manager
(openclaw_home, hub_base=None)
tests/test_skill_manager.py:9
↓ 3 callers
Function
_lock_path
(path: pathlib.Path)
scripts/file_lock.py:59
↓ 3 callers
Function
_parse_activity_entry
将 session jsonl 的 message 统一解析成看板活动条目。
dashboard/server.py:1478
↓ 3 callers
Function
_parse_iso
(ts)
dashboard/server.py:1033
↓ 3 callers
Function
_sanitize_remark
清洗流转备注(最长 120 字符)。
scripts/kanban_update.py:230
↓ 3 callers
Function
_unlock
释放锁。
scripts/file_lock.py:48
↓ 3 callers
Function
add_remote
从远程 URL 为 Agent 添加 skill
scripts/skill_manager.py:73
↓ 3 callers
Function
close
()
edict/frontend/src/components/TaskModal.tsx:112
↓ 3 callers
Function
cmd_done
执行部门回报完成,任务进入 Review 待尚书省汇总审查。
scripts/kanban_update.py:440
↓ 3 callers
Function
doTaskAction
(action: string, reason: string)
edict/frontend/src/components/TaskModal.tsx:124
↓ 3 callers
Function
extractAgent
(t: Task)
edict/frontend/src/components/SessionsPanel.tsx:20
↓ 3 callers
Function
fmtActivityTime
(ts: number | string | undefined)
edict/frontend/src/components/TaskModal.tsx:46
↓ 3 callers
Function
formatDashboardDateTime
( value: number | string | undefined | null, { showSeconds = true }: { showSeconds?: boolean } = {} )
edict/frontend/src/time.ts:48
↓ 3 callers
Function
getPipeStatus
(t: Task)
edict/frontend/src/store.ts:74
↓ 3 callers
Function
get_agent_activity
从 Agent 的 session jsonl 读取最近活动。 如果 task_id 不为空,只返回提及该 task_id 的相关条目。
dashboard/server.py:1551
↓ 3 callers
Function
handleAction
(action: string, e: React.MouseEvent)
edict/frontend/src/components/EdictBoard.tsx:44
↓ 3 callers
Function
modify_task
Atomically update a single task identified by *task_id*. ``updater(task)`` receives the task dict and should mutate it in place. Returns ``Tr
dashboard/server.py:179
↓ 3 callers
Function
normalize_model
(model_value, fallback='anthropic/claude-sonnet-4-6')
scripts/sync_officials_stats.py:58
↓ 3 callers
Function
rj
(path, default)
scripts/apply_model_changes.py:19
↓ 3 callers
Method
send_file
(self, path: pathlib.Path, mime='text/html; charset=utf-8')
dashboard/server.py:2364
↓ 3 callers
Function
stateLabel
(t: Task)
edict/frontend/src/store.ts:53
↓ 3 callers
Function
wake_agent
唤醒指定 Agent,发送一条心跳/唤醒消息。
dashboard/server.py:973
↓ 2 callers
Function
_check_agent_workspace
检查 Agent 工作空间是否存在。
dashboard/server.py:881
↓ 2 callers
Method
_check_auth
检查认证,未通过返回 True(已发送 401 响应)。
dashboard/server.py:2392
↓ 2 callers
Function
_check_gateway_probe
通过 HTTP probe 检测 Gateway 是否响应。
dashboard/server.py:831
↓ 2 callers
Method
_dispatch
执行一次 agent 派发(桶级并发控制)。
edict/backend/app/workers/dispatch_worker.py:382
↓ 2 callers
Method
_handle_event
根据 topic 和 event_type 分发处理。
edict/backend/app/workers/orchestrator_worker.py:149
↓ 2 callers
Function
_llm_complete
调用 LLM API(自动适配 GitHub Copilot / OpenAI / Anthropic 协议)。
dashboard/court_discuss.py:430
↓ 2 callers
Function
_lock_exclusive
获取排他锁(写锁)。
scripts/file_lock.py:40
↓ 2 callers
Function
_resolve_agents_dir
定位 agents/ 目录。
edict/backend/app/workers/dispatch_worker.py:67
↓ 2 callers
Function
_sanitize_remark
(raw)
edict/scripts/kanban_update_edict.py:74
↓ 2 callers
Function
_sanitize_text
(raw, max_len=80)
edict/scripts/kanban_update_edict.py:56
↓ 2 callers
Function
_sanitize_text
清洗文本:剥离文件路径、URL、Conversation 元数据、传旨前缀、截断过长内容。
scripts/kanban_update.py:202
↓ 2 callers
Function
_serialize
(session: dict)
dashboard/court_discuss.py:710
↓ 2 callers
Function
_sync_script_symlink
Create a symlink dst_file → src_file (resolved). Using symlinks instead of physical copies ensures that ``__file__`` in each script always re
scripts/sync_agent_config.py:225
↓ 2 callers
Function
_trigger_refresh
Trigger live data refresh in background.
dashboard/server.py:148
↓ 2 callers
Method
add_progress
( self, task_id: uuid.UUID, agent: str, content: str, )
edict/backend/app/services/task_service.py:200
↓ 2 callers
Function
add_remote_skill
从远程 URL 或本地路径为 Agent 添加 skill SKILL.md 文件。 支持的源: - HTTPS URLs: https://raw.githubusercontent.com/... - 本地路径: /path/to/SKILL.md 或 file
dashboard/server.py:351
↓ 2 callers
Function
buildCmd
(tpl: Template)
edict/frontend/src/components/TemplatePanel.tsx:29
↓ 2 callers
Function
channelLabel
(t: Task)
edict/frontend/src/components/SessionsPanel.tsx:40
next →
1–100 of 535, ranked by callers