← Về thư mục
📄 / / root / ceo / skills / research / policy-lab / references / lark-cli-binding.md

Lark CLI binding & workflow notes for Policy Lab tracking

Purpose

Use lark-cli to track research phase status and mirror research files when the user wants visibility inside Lark Docs and Base.

Key workflows discovered

1. Identity & Binding

2. Multi-layered tracking structure

Avoid duplicating the research content inside Lark Base. Instead, maintain three clean layers: - Source of truth: local RES_YYYYMMDD_Name.md file. Always up to date, detailed, and formatted for AI reading. - Mirror: a Lark Doc named after the topic (e.g. VietnamTourismData), updated after each phase to reflect the current state. - Tracker: records inside the Lark Base Research Tasks table mapping to research phases, containing status, record link, and follow-up notes.

3. Scope progression & Split-flow

For CLI scopes that require browser approval (e.g., doc creation, modification), use the split-flow: 1. Trigger fresh login: lark-cli auth login --scope "docx:document:create" --no-wait --json 2. Extract URL and return control to the user. 3. Upon user's "done", resume: lark-cli auth login --device-code <device_code> 4. Note that scopes are cumulative (incremental). E.g., docx:document:create and docx:document:write_only must both be granted to support doc create and overwrite workflows.

4. CLI command gotchas