docs: sync README files with recent changes
This commit is contained in:
@@ -62,16 +62,16 @@ See [docs/architecture.md](docs/architecture.md) for the full design — three-p
|
|||||||
uwf setup
|
uwf setup
|
||||||
|
|
||||||
# 2. Register a workflow from YAML
|
# 2. Register a workflow from YAML
|
||||||
uwf workflow put examples/solve-issue.yaml
|
uwf workflow add examples/solve-issue.yaml
|
||||||
|
|
||||||
# 3. Start a thread (creates head pointer; does not execute)
|
# 3. Start a thread (creates head pointer; does not execute)
|
||||||
uwf thread start solve-issue -p "Fix the login redirect bug"
|
uwf thread start solve-issue -p "Fix the login redirect bug"
|
||||||
|
|
||||||
# 4. Execute steps (one at a time, until done)
|
# 4. Execute steps (one at a time, until done)
|
||||||
uwf thread step <thread-id>
|
uwf thread exec <thread-id>
|
||||||
```
|
```
|
||||||
|
|
||||||
Use `-c, --count <number>` on `thread step` to run multiple steps in one invocation. Override the agent with `--agent <cmd>`.
|
Use `-c, --count <number>` on `thread exec` to run multiple steps in one invocation. Override the agent with `--agent <cmd>`.
|
||||||
|
|
||||||
## CLI Reference
|
## CLI Reference
|
||||||
|
|
||||||
@@ -79,8 +79,9 @@ Global options: `-V, --version`, `--format <json|yaml>`, `-h, --help`.
|
|||||||
|
|
||||||
| Group | Commands |
|
| Group | Commands |
|
||||||
|-------|----------|
|
|-------|----------|
|
||||||
| **thread** | `start`, `step`, `show`, `list`, `kill`, `steps`, `read`, `fork`, `step-details` |
|
| **thread** | `start`, `exec`, `show`, `list`, `stop`, `cancel`, `read` |
|
||||||
| **workflow** | `put`, `show`, `list` |
|
| **step** | `list`, `show`, `fork` |
|
||||||
|
| **workflow** | `add`, `show`, `list` |
|
||||||
| **cas** | `get`, `put`, `put-text`, `has`, `refs`, `walk`, `reindex`, `schema list`, `schema get` |
|
| **cas** | `get`, `put`, `put-text`, `has`, `refs`, `walk`, `reindex`, `schema list`, `schema get` |
|
||||||
| **setup** | Interactive or `--provider`, `--base-url`, `--api-key`, `--model`, `--agent` |
|
| **setup** | Interactive or `--provider`, `--base-url`, `--api-key`, `--model`, `--agent` |
|
||||||
| **skill** | `cli` — print markdown reference of all uwf commands |
|
| **skill** | `cli` — print markdown reference of all uwf commands |
|
||||||
|
|||||||
@@ -49,8 +49,10 @@ bun link packages/cli-workflow
|
|||||||
| `uwf thread start <workflow> -p <prompt>` | Create a thread without executing |
|
| `uwf thread start <workflow> -p <prompt>` | Create a thread without executing |
|
||||||
| `uwf thread exec <thread-id> [--agent <cmd>] [-c <count>] [--background]` | Execute one or more moderator→agent→extract cycles |
|
| `uwf thread exec <thread-id> [--agent <cmd>] [-c <count>] [--background]` | Execute one or more moderator→agent→extract cycles |
|
||||||
| `uwf thread show <thread-id>` | Show thread head pointer |
|
| `uwf thread show <thread-id>` | Show thread head pointer |
|
||||||
| `uwf thread list [--status <idle\|running\|completed>]` | List threads, optionally filtered by status |
|
| `uwf thread list [--status <status>] [--after <date>] [--before <date>] [--skip <n>] [--take <n>]` | List threads filtered by status (idle, running, completed, active, or comma-separated), time range (ISO or relative like '7d'), with pagination |
|
||||||
| `uwf thread read <thread-id> [--quota N] [--before <hash>] [--start]` | Render thread as readable markdown |
|
| `uwf thread read <thread-id> [--quota N] [--before <hash>] [--start]` | Render thread as readable markdown |
|
||||||
|
|
||||||
|
`thread read`, `step list`, and `step show` work on both active and completed threads.
|
||||||
| `uwf thread stop <thread-id>` | Stop background execution (keep thread active) |
|
| `uwf thread stop <thread-id>` | Stop background execution (keep thread active) |
|
||||||
| `uwf thread cancel <thread-id>` | Cancel thread (stop + archive to history) |
|
| `uwf thread cancel <thread-id>` | Cancel thread (stop + archive to history) |
|
||||||
|
|
||||||
@@ -62,6 +64,9 @@ uwf thread exec 01ARZ3NDEKTSV4RRFFQ69G5FAV
|
|||||||
uwf thread exec 01ARZ3NDEKTSV4RRFFQ69G5FAV -c 3 --agent uwf-builtin
|
uwf thread exec 01ARZ3NDEKTSV4RRFFQ69G5FAV -c 3 --agent uwf-builtin
|
||||||
uwf thread exec 01ARZ3NDEKTSV4RRFFQ69G5FAV --background
|
uwf thread exec 01ARZ3NDEKTSV4RRFFQ69G5FAV --background
|
||||||
uwf thread list --status running
|
uwf thread list --status running
|
||||||
|
uwf thread list --status active
|
||||||
|
uwf thread list --status idle,completed
|
||||||
|
uwf thread list --after 7d --take 10
|
||||||
uwf thread read 01ARZ3NDEKTSV4RRFFQ69G5FAV --quota 8000
|
uwf thread read 01ARZ3NDEKTSV4RRFFQ69G5FAV --quota 8000
|
||||||
uwf thread stop 01ARZ3NDEKTSV4RRFFQ69G5FAV
|
uwf thread stop 01ARZ3NDEKTSV4RRFFQ69G5FAV
|
||||||
```
|
```
|
||||||
|
|||||||
@@ -83,9 +83,10 @@ Requires `UWF_EDGE_PROMPT` in the environment (set by `uwf thread step`).
|
|||||||
function buildRolePrompt(role: RoleDefinition): string
|
function buildRolePrompt(role: RoleDefinition): string
|
||||||
function buildOutputFormatInstruction(schema: JSONSchema): string
|
function buildOutputFormatInstruction(schema: JSONSchema): string
|
||||||
function buildContinuationPrompt(
|
function buildContinuationPrompt(
|
||||||
ctx: AgentContext,
|
steps: StepContext[],
|
||||||
priorOutput: string,
|
role: string,
|
||||||
instruction: string,
|
edgePrompt: string,
|
||||||
|
options?: { includeContent?: boolean; quota?: number },
|
||||||
): string
|
): string
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|||||||
@@ -92,7 +92,7 @@ type StepNodePayload = StepRecord & {
|
|||||||
### Moderator context
|
### Moderator context
|
||||||
|
|
||||||
```typescript
|
```typescript
|
||||||
type StepContext = Omit<StepRecord, "output"> & { output: unknown };
|
type StepContext = Omit<StepRecord, "output"> & { output: unknown; content: string | null };
|
||||||
|
|
||||||
type ModeratorContext = {
|
type ModeratorContext = {
|
||||||
start: StartNodePayload;
|
start: StartNodePayload;
|
||||||
|
|||||||
@@ -23,6 +23,7 @@ All exports come from `src/index.ts`.
|
|||||||
```typescript
|
```typescript
|
||||||
function encodeUint64AsCrockford(value: bigint): string
|
function encodeUint64AsCrockford(value: bigint): string
|
||||||
function generateUlid(nowMs: number): string
|
function generateUlid(nowMs: number): string
|
||||||
|
function extractUlidTimestamp(ulid: string): number | null
|
||||||
```
|
```
|
||||||
|
|
||||||
### Logging
|
### Logging
|
||||||
|
|||||||
Reference in New Issue
Block a user