facult 2.6.0 → 2.7.1
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 +145 -337
- package/package.json +1 -1
- package/src/adapters/codex.ts +1 -1
- package/src/audit/agent.ts +26 -24
- package/src/audit/fix.ts +875 -0
- package/src/audit/index.ts +51 -2
- package/src/audit/safe.ts +596 -0
- package/src/audit/static.ts +151 -34
- package/src/audit/status.ts +21 -0
- package/src/audit/suppressions.ts +266 -0
- package/src/audit/tui.ts +784 -174
- package/src/audit/update-index.ts +4 -17
- package/src/builtin.ts +7 -1
- package/src/cli-ui.ts +375 -0
- package/src/consolidate.ts +151 -55
- package/src/doctor.ts +327 -0
- package/src/global-docs.ts +43 -2
- package/src/index.ts +571 -292
- package/src/manage.ts +931 -88
- package/src/mcp-config.ts +132 -0
- package/src/project-sync.ts +288 -0
- package/src/remote.ts +387 -117
- package/src/trust.ts +119 -11
- package/src/util/git.ts +95 -0
package/README.md
CHANGED
|
@@ -24,170 +24,14 @@
|
|
|
24
24
|
|
|
25
25
|
`fclt` is a CLI for building and evolving AI faculties across tools, users, and projects.
|
|
26
26
|
|
|
27
|
-
|
|
27
|
+
`fclt` manages the reusable parts of your AI setup: instructions, snippets, templates, skills, agents, rules, and the feedback loops that improve them over time.
|
|
28
28
|
|
|
29
29
|
It helps you:
|
|
30
|
-
-
|
|
31
|
-
-
|
|
32
|
-
-
|
|
33
|
-
-
|
|
34
|
-
-
|
|
35
|
-
- sync managed outputs into Codex, Cursor, and Claude
|
|
36
|
-
- review trust/security before installing remote content
|
|
37
|
-
- keep that operating layer in a git-backed store under `~/.ai` and repo-local `.ai/`
|
|
38
|
-
|
|
39
|
-
## What fclt Is
|
|
40
|
-
|
|
41
|
-
If your agent setup feels scattered, `fclt` gives it memory, structure, and a way to improve.
|
|
42
|
-
|
|
43
|
-
A faculty is a reusable piece of AI behavior: an instruction, snippet, template, skill, agent, rule, or learned improvement that you want to keep around and make better.
|
|
44
|
-
|
|
45
|
-
That matters because a lot of useful AI behavior is compositional. You want small reusable blocks, a clean way to assemble them into bigger prompts and operating layers, and a safe way to render the final tool-native outputs without losing the source structure.
|
|
46
|
-
|
|
47
|
-
Think of it as:
|
|
48
|
-
- a canonical home for your AI faculties
|
|
49
|
-
- a composition system for snippets, templates, and rendered AI behavior
|
|
50
|
-
- a sync layer for projecting them into real tools
|
|
51
|
-
- a discovery graph for seeing what exists and what depends on what
|
|
52
|
-
- a writeback/evolution loop for turning repeated friction into durable improvements
|
|
53
|
-
- an inventory and trust boundary for the assets you let into the system
|
|
54
|
-
|
|
55
|
-
## What fclt Does
|
|
56
|
-
|
|
57
|
-
`fclt` is not a skills folder with a nicer CLI.
|
|
58
|
-
|
|
59
|
-
It works as five connected layers:
|
|
60
|
-
|
|
61
|
-
1. Canonical source
|
|
62
|
-
- global capability in `~/.ai`
|
|
63
|
-
- project capability in `<repo>/.ai`
|
|
64
|
-
- optional built-in Facult capability packs for bootstrap and defaults
|
|
65
|
-
2. Discovery
|
|
66
|
-
- inventory across skills, agents, snippets, instructions, MCP, and rendered surfaces
|
|
67
|
-
- merged views across builtin, global, and project provenance
|
|
68
|
-
- explicit dependency graph queries
|
|
69
|
-
3. Sync
|
|
70
|
-
- managed tool outputs for Codex, Claude, Cursor, and other file-backed surfaces
|
|
71
|
-
- rendered docs, agents, skills, MCP, config, and rules
|
|
72
|
-
4. Automation
|
|
73
|
-
- background autosync for local propagation
|
|
74
|
-
- optional git autosync for the canonical store
|
|
75
|
-
5. Evolution
|
|
76
|
-
- writeback capture
|
|
77
|
-
- proposal drafting and review
|
|
78
|
-
- controlled apply back into canonical assets
|
|
79
|
-
|
|
80
|
-
## Default Operating Model
|
|
81
|
-
|
|
82
|
-
`fclt` ships with a built-in operating model for learning, writeback, and capability evolution. That pack includes default:
|
|
83
|
-
|
|
84
|
-
- instructions for evolution, integration, and project capability
|
|
85
|
-
- specialist agents such as `writeback-curator`, `evolution-planner`, and `scope-promoter`
|
|
86
|
-
- skills such as `capability-evolution` and `project-operating-layer-design`
|
|
87
|
-
|
|
88
|
-
When managed sync is enabled, these built-in assets are available by default even if you never copy them into `~/.ai`.
|
|
89
|
-
|
|
90
|
-
That means:
|
|
91
|
-
- builtin skills sync into managed tool skill directories by default
|
|
92
|
-
- builtin agents sync into tool agent directories when the tool supports agents
|
|
93
|
-
- if you do not author your own `AGENTS.global.md`, `fclt` renders a builtin global baseline doc into tool-native global docs
|
|
94
|
-
|
|
95
|
-
The activation point is managed mode:
|
|
96
|
-
- until you run `fclt manage <tool>`, the builtin operating-model layer is just packaged capability
|
|
97
|
-
- once a tool is managed, the default operating-model layer becomes live for that tool automatically
|
|
98
|
-
- for Codex, Claude, and Cursor, that means the core global doc surface plus the bundled writeback/evolution agents and skills are what agents actually see on disk
|
|
99
|
-
- this is why the normal setup step is to manage the tools you care about first, then sync
|
|
100
|
-
|
|
101
|
-
This is intentionally virtual at the canonical level:
|
|
102
|
-
- builtin defaults remain part of the packaged tool
|
|
103
|
-
- your personal `~/.ai` stays clean unless you explicitly vendor or override something
|
|
104
|
-
- the live tool output on disk still contains the rendered defaults, so users and agents can read them directly
|
|
105
|
-
|
|
106
|
-
In practice, this means the system is meant to learn by default. The CLI is there when you want to operate it directly, but the default skills, agents, and global docs are supposed to make writeback and evolution available without ceremony.
|
|
107
|
-
|
|
108
|
-
More concretely:
|
|
109
|
-
- the normal path is not a human manually typing `fclt ai ...` after every task
|
|
110
|
-
- the bundled operating-model layer is meant to instruct synced agents and skills to notice reusable signal, preserve it, and push it toward writeback/evolution
|
|
111
|
-
- the CLI remains the explicit operator surface for inspection, review, cleanup, and controlled apply
|
|
112
|
-
- the generated state under `.ai/.facult/` gives those agents a durable thread of what was learned, when it was learned, what asset it pointed at, and what proposals or reviews happened afterward
|
|
113
|
-
|
|
114
|
-
If you want to disable the builtin default layer for a specific global or project canonical root:
|
|
115
|
-
|
|
116
|
-
```toml
|
|
117
|
-
version = 1
|
|
118
|
-
|
|
119
|
-
[builtin]
|
|
120
|
-
sync_defaults = false
|
|
121
|
-
```
|
|
122
|
-
|
|
123
|
-
Put that in `config.toml` or `config.local.toml` under the active canonical root.
|
|
124
|
-
|
|
125
|
-
## Core Concepts
|
|
126
|
-
|
|
127
|
-
### Canonical vs rendered
|
|
128
|
-
|
|
129
|
-
`fclt` separates source-of-truth from tool-native output.
|
|
130
|
-
|
|
131
|
-
- canonical source lives in `~/.ai` or `<repo>/.ai`
|
|
132
|
-
- rendered outputs live in tool homes like `~/.codex`, `<repo>/.codex`, `~/.claude`, or `~/.cursor`
|
|
133
|
-
- generated Facult-owned state lives in `~/.ai/.facult` or `<repo>/.ai/.facult`
|
|
134
|
-
|
|
135
|
-
This keeps authored capability portable and reviewable while still producing the exact files each tool expects.
|
|
136
|
-
|
|
137
|
-
### Global vs project capability
|
|
138
|
-
|
|
139
|
-
Use global `~/.ai` for reusable personal defaults:
|
|
140
|
-
- cross-project instructions
|
|
141
|
-
- reusable specialist agents
|
|
142
|
-
- shared skills
|
|
143
|
-
- default tool config and rules
|
|
144
|
-
|
|
145
|
-
Use project `.ai/` for repo-owned capability:
|
|
146
|
-
- project-specific instructions and snippets
|
|
147
|
-
- local architecture/testing doctrine
|
|
148
|
-
- project agents and skills that should travel with the codebase
|
|
149
|
-
- repo-local rendered outputs for teammates
|
|
150
|
-
|
|
151
|
-
Project capability is allowed to extend or shadow global capability in merged views, but it does not silently mutate the global source of truth.
|
|
152
|
-
|
|
153
|
-
### The capability graph
|
|
154
|
-
|
|
155
|
-
`fclt` builds a generated graph of explicit relationships between canonical assets and rendered outputs.
|
|
156
|
-
|
|
157
|
-
That graph tracks things like:
|
|
158
|
-
- snippet markers
|
|
159
|
-
- `@ai/...` and `@project/...` refs
|
|
160
|
-
- `${refs.*}` symbolic refs
|
|
161
|
-
- rendered-target edges from canonical source to live tool files
|
|
162
|
-
|
|
163
|
-
This makes it possible to answer:
|
|
164
|
-
- what capability do I already have?
|
|
165
|
-
- what instructions or snippets does this agent depend on?
|
|
166
|
-
- what rendered files change if I update this canonical asset?
|
|
167
|
-
- what project asset is shadowing a global asset?
|
|
168
|
-
|
|
169
|
-
### Writeback and evolution
|
|
170
|
-
|
|
171
|
-
`fclt` treats repeated failures, weak loops, missing context, and reusable patterns as signal worth preserving.
|
|
172
|
-
|
|
173
|
-
Writeback is the act of recording that signal in a structured way.
|
|
174
|
-
Evolution is the act of grouping that signal into reviewable proposals and applying it back into canonical assets.
|
|
175
|
-
|
|
176
|
-
The intended workflow is agent-driven by default:
|
|
177
|
-
- synced global docs, agents, and skills should push your tooling toward creating writebacks when something important was learned
|
|
178
|
-
- specialist agents such as `writeback-curator`, `evolution-planner`, and `scope-promoter` are there to help turn that signal into cleaner proposals and scope decisions
|
|
179
|
-
- the CLI is what you use when you want to inspect, override, review, reject, apply, or otherwise operate the system directly
|
|
180
|
-
- the point is not a new UI. The point is that the operating layer itself can accumulate memory and context across tasks, sessions, and tools
|
|
181
|
-
|
|
182
|
-
This matters because otherwise the same problems repeat in chat without ever improving the actual operating layer. With `fclt`, you can:
|
|
183
|
-
- record a weak verification pattern
|
|
184
|
-
- group repeated writebacks around an instruction or agent
|
|
185
|
-
- draft a proposal to tighten that canonical asset
|
|
186
|
-
- review and apply the change in a controlled way
|
|
187
|
-
|
|
188
|
-
The point is not just better storage. The point is that your AI setup can change shape as it learns.
|
|
189
|
-
|
|
190
|
-
That is the core idea behind `fclt`: not just syncing skills, but growing faculties.
|
|
30
|
+
- keep a canonical store in `~/.ai` or `<repo>/.ai`
|
|
31
|
+
- render managed tool files into Codex, Claude, Cursor, and similar tools
|
|
32
|
+
- inspect dependencies, provenance, and rendered outputs
|
|
33
|
+
- review trust and audit remote or local capability before it spreads
|
|
34
|
+
- capture writebacks and evolve canonical assets over time
|
|
191
35
|
|
|
192
36
|
## Quick Start
|
|
193
37
|
|
|
@@ -241,67 +85,64 @@ Pin to a specific version:
|
|
|
241
85
|
fclt self-update --version 0.0.1
|
|
242
86
|
```
|
|
243
87
|
|
|
244
|
-
### 2.
|
|
88
|
+
### 2. Scan or bootstrap your canonical store
|
|
245
89
|
|
|
246
90
|
```bash
|
|
247
91
|
fclt scan --show-duplicates
|
|
248
|
-
# optional machine-readable output
|
|
249
|
-
fclt scan --json
|
|
250
92
|
```
|
|
251
93
|
|
|
252
|
-
`scan` is read-only. It inspects local configs and reports what `
|
|
94
|
+
`scan` is read-only. It inspects local configs and reports what `fclt` found without changing files.
|
|
253
95
|
|
|
254
|
-
|
|
96
|
+
If you want a repo-local `.ai`:
|
|
255
97
|
|
|
256
98
|
```bash
|
|
257
|
-
|
|
99
|
+
cd /path/to/repo
|
|
100
|
+
fclt templates init project-ai
|
|
258
101
|
fclt index
|
|
259
102
|
```
|
|
260
103
|
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
Canonical source root: `~/.ai` for global work, or `<repo>/.ai` for project-local work.
|
|
104
|
+
### 3. Import existing skills or config
|
|
264
105
|
|
|
265
|
-
|
|
266
|
-
-
|
|
267
|
-
|
|
106
|
+
```bash
|
|
107
|
+
fclt consolidate --auto keep-current --from ~/.codex/skills --from ~/.agents/skills
|
|
108
|
+
fclt index
|
|
109
|
+
```
|
|
268
110
|
|
|
269
|
-
|
|
270
|
-
- macOS state: `~/Library/Application Support/fclt/...`
|
|
271
|
-
- macOS cache: `~/Library/Caches/fclt/...`
|
|
272
|
-
- Linux/other state: `${XDG_STATE_HOME:-~/.local/state}/fclt/...`
|
|
273
|
-
- Linux/other cache: `${XDG_CACHE_HOME:-~/.cache}/fclt/...`
|
|
111
|
+
Why `keep-current`: it is deterministic and non-interactive for duplicate sources.
|
|
274
112
|
|
|
275
|
-
###
|
|
113
|
+
### 4. Manage a tool and sync
|
|
276
114
|
|
|
277
115
|
```bash
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
116
|
+
fclt manage codex --dry-run
|
|
117
|
+
fclt manage codex --adopt-existing
|
|
118
|
+
fclt sync codex --builtin-conflicts overwrite
|
|
119
|
+
fclt manage cursor
|
|
120
|
+
fclt manage claude
|
|
121
|
+
|
|
122
|
+
fclt enable requesting-code-review receiving-code-review brainstorming systematic-debugging --for codex,cursor,claude
|
|
123
|
+
fclt sync
|
|
281
124
|
```
|
|
282
125
|
|
|
283
|
-
|
|
126
|
+
Use `--dry-run` first if the live tool already has local content. If the tool already contains skills, agents, rules, docs, config, or MCP definitions, rerun with `--adopt-existing` and add `--existing-conflicts keep-canonical|keep-existing` if names collide.
|
|
284
127
|
|
|
285
|
-
|
|
128
|
+
Codex path policy:
|
|
129
|
+
- skills render to `.agents/skills`
|
|
130
|
+
- local plugin marketplaces render to `.agents/plugins/marketplace.json`
|
|
131
|
+
- local plugin bundles render to `plugins/`
|
|
132
|
+
- Codex runtime config, rules, agents, and automations still render under `.codex/`
|
|
286
133
|
|
|
287
|
-
|
|
134
|
+
If you run these commands inside a repo that has `<repo>/.ai`, `fclt` targets the project-local canonical store and repo-local tool outputs by default.
|
|
135
|
+
|
|
136
|
+
### 5. Inspect and evolve
|
|
288
137
|
|
|
289
138
|
```bash
|
|
290
139
|
fclt list skills
|
|
291
|
-
fclt list instructions
|
|
292
|
-
fclt list mcp
|
|
293
|
-
fclt show requesting-code-review
|
|
294
140
|
fclt show instruction:WRITING
|
|
295
141
|
fclt show mcp:github
|
|
296
142
|
fclt find verification
|
|
297
|
-
fclt graph
|
|
298
|
-
fclt graph deps AGENTS.global.md
|
|
299
|
-
fclt graph dependents @ai/instructions/WRITING.md
|
|
143
|
+
fclt graph AGENTS.global.md
|
|
300
144
|
fclt ai writeback add --kind weak_verification --summary "Checks were too shallow" --asset instruction:VERIFICATION
|
|
301
145
|
fclt ai evolve propose
|
|
302
|
-
fclt ai evolve draft EV-00001
|
|
303
|
-
fclt ai evolve accept EV-00001
|
|
304
|
-
fclt ai evolve apply EV-00001
|
|
305
146
|
```
|
|
306
147
|
|
|
307
148
|
Context controls:
|
|
@@ -310,66 +151,67 @@ Context controls:
|
|
|
310
151
|
fclt list instructions --global
|
|
311
152
|
fclt list instructions --project
|
|
312
153
|
fclt find verification --scope merged --source project
|
|
313
|
-
fclt sync codex --project
|
|
314
|
-
fclt autosync status --global
|
|
315
154
|
fclt list agents --root /path/to/repo/.ai
|
|
316
155
|
```
|
|
317
156
|
|
|
318
|
-
###
|
|
157
|
+
### 6. Optional: autosync, source trust, and audit
|
|
319
158
|
|
|
320
159
|
```bash
|
|
321
|
-
fclt
|
|
322
|
-
fclt
|
|
323
|
-
fclt sync codex --builtin-conflicts overwrite
|
|
324
|
-
fclt manage cursor
|
|
325
|
-
fclt manage claude
|
|
160
|
+
fclt autosync install --git-remote origin --git-branch main --git-interval-minutes 60
|
|
161
|
+
fclt autosync status
|
|
326
162
|
|
|
327
|
-
fclt
|
|
328
|
-
fclt
|
|
163
|
+
fclt sources list
|
|
164
|
+
fclt verify-source skills.sh --json
|
|
165
|
+
fclt sources trust skills.sh --note "reviewed"
|
|
166
|
+
fclt install skills.sh:code-review --as code-review-skills-sh --strict-source-trust
|
|
167
|
+
|
|
168
|
+
fclt audit
|
|
169
|
+
fclt audit --non-interactive --severity high
|
|
170
|
+
fclt audit safe mcp:github --rule static:mcp-env-inline-secret --note "reviewed"
|
|
171
|
+
fclt audit fix mcp:github
|
|
329
172
|
```
|
|
330
173
|
|
|
331
|
-
|
|
332
|
-
This is also the point where the default operating-model layer becomes active for those tools. If you manage Codex or Claude, the bundled learning/writeback/evolution guidance is no longer just discoverable in `fclt`; it is rendered into the managed global doc surface and synced alongside the bundled agents and skills.
|
|
174
|
+
## Overview
|
|
333
175
|
|
|
334
|
-
|
|
335
|
-
On first entry to managed mode, use `--dry-run` first if the live tool already has local content. `facult` will show what it would adopt into the active canonical store across skills, agents, docs, rules, config, and MCP, plus any conflicts. Then rerun with `--adopt-existing`; if names or files collide, add `--existing-conflicts keep-canonical` or `--existing-conflicts keep-existing`.
|
|
336
|
-
For builtin-backed rendered defaults, `facult` now tracks the last managed render hash. If a user edits the generated target locally, normal sync warns and preserves that local edit instead of silently overwriting it. To replace the local edit with the latest packaged builtin default, rerun sync with `--builtin-conflicts overwrite`.
|
|
176
|
+
Useful AI behavior is composable. You need small reusable parts, a clean way to combine them, and a safe way to render them into the files your tools actually use.
|
|
337
177
|
|
|
338
|
-
|
|
178
|
+
`fclt` is a canonical store plus a renderer:
|
|
179
|
+
- canonical store in `~/.ai` or `<repo>/.ai`
|
|
180
|
+
- rendered tool files in places like `~/.codex`, `~/.claude`, or repo-local tool dirs
|
|
181
|
+
- discovery and graph views for dependencies, provenance, and rendered targets
|
|
182
|
+
- writeback and evolution flows for improving canonical assets over time
|
|
339
183
|
|
|
340
|
-
|
|
341
|
-
fclt autosync install --git-remote origin --git-branch main --git-interval-minutes 60
|
|
342
|
-
fclt autosync status
|
|
343
|
-
```
|
|
184
|
+
## Built-in Defaults
|
|
344
185
|
|
|
345
|
-
|
|
346
|
-
-
|
|
347
|
-
-
|
|
348
|
-
-
|
|
186
|
+
`fclt` includes a built-in layer for writeback and evolution. By default, that layer provides:
|
|
187
|
+
- instructions for evolution, integration, and project capability
|
|
188
|
+
- agents such as `writeback-curator`, `evolution-planner`, and `scope-promoter`
|
|
189
|
+
- skills such as `capability-evolution` and `project-operating-layer-design`
|
|
349
190
|
|
|
350
|
-
|
|
191
|
+
Those built-in defaults become live when you manage a tool. Global tool management renders the bundled docs, agents, and skills into that tool’s live files. Project-local `.ai` roots do not sync the built-in operating-model layer unless you explicitly enable it.
|
|
351
192
|
|
|
352
|
-
|
|
193
|
+
If you want to disable default built-in sync for one canonical root:
|
|
353
194
|
|
|
354
|
-
```
|
|
355
|
-
|
|
356
|
-
fclt verify-source skills.sh --json
|
|
357
|
-
fclt sources trust skills.sh --note "reviewed"
|
|
195
|
+
```toml
|
|
196
|
+
version = 1
|
|
358
197
|
|
|
359
|
-
|
|
198
|
+
[builtin]
|
|
199
|
+
sync_defaults = false
|
|
360
200
|
```
|
|
361
201
|
|
|
202
|
+
Put that in `config.toml` or `config.local.toml` under the active canonical root.
|
|
203
|
+
|
|
362
204
|
## Use fclt from your agents
|
|
363
205
|
|
|
364
|
-
`
|
|
365
|
-
1. Install `
|
|
366
|
-
2. Put allowed `
|
|
367
|
-
3. Optionally scaffold MCP wrappers if you want an MCP entry that delegates to `
|
|
206
|
+
`fclt` is CLI-first. The practical setup is:
|
|
207
|
+
1. Install `fclt` globally so any agent runtime can execute it.
|
|
208
|
+
2. Put allowed `fclt` workflows in your agent instructions and skills.
|
|
209
|
+
3. Optionally scaffold MCP wrappers if you want an MCP entry that delegates to `fclt`.
|
|
368
210
|
|
|
369
211
|
```bash
|
|
370
212
|
# Scaffold reusable templates in the canonical store
|
|
371
213
|
fclt templates init agents
|
|
372
|
-
fclt templates init
|
|
214
|
+
fclt templates init agent review-operator
|
|
373
215
|
fclt templates init skill facult-manager
|
|
374
216
|
|
|
375
217
|
# Enable that skill for managed tools
|
|
@@ -390,9 +232,9 @@ fclt sync
|
|
|
390
232
|
|
|
391
233
|
Note: `templates init mcp ...` is a scaffold, not a running server by itself.
|
|
392
234
|
|
|
393
|
-
##
|
|
235
|
+
## Mental Model
|
|
394
236
|
|
|
395
|
-
`
|
|
237
|
+
`fclt` treats both `~/.ai` and `<repo>/.ai` as canonical stores. The global store is for personal reusable capability. The project store is for repo-owned capability that should travel with the codebase.
|
|
396
238
|
|
|
397
239
|
Typical layout:
|
|
398
240
|
|
|
@@ -411,6 +253,8 @@ Typical layout:
|
|
|
411
253
|
tools/
|
|
412
254
|
codex/
|
|
413
255
|
config.toml
|
|
256
|
+
plugins/
|
|
257
|
+
marketplace.json
|
|
414
258
|
rules/
|
|
415
259
|
<repo>/
|
|
416
260
|
.ai/
|
|
@@ -425,6 +269,8 @@ Typical layout:
|
|
|
425
269
|
index.json
|
|
426
270
|
graph.json
|
|
427
271
|
.codex/
|
|
272
|
+
.agents/
|
|
273
|
+
plugins/
|
|
428
274
|
.claude/
|
|
429
275
|
```
|
|
430
276
|
|
|
@@ -444,6 +290,7 @@ The canonical store can contain several distinct asset classes:
|
|
|
444
290
|
- `agents/`: role-specific agent manifests
|
|
445
291
|
- `skills/`: workflow-specific capability folders
|
|
446
292
|
- `mcp/`: canonical MCP server definitions
|
|
293
|
+
- `mcp/servers.local.json` or `mcp/mcp.local.json`: ignored machine-local MCP secret overlay
|
|
447
294
|
- `tools/<tool>/config.toml`: canonical tool config
|
|
448
295
|
- `tools/<tool>/config.local.toml`: machine-local tool config overlay
|
|
449
296
|
- `tools/<tool>/rules/*.rules`: canonical tool rules
|
|
@@ -457,14 +304,14 @@ Not every asset syncs directly to a tool. Some exist primarily to support render
|
|
|
457
304
|
- Use `snippets/` for composable partial blocks injected into markdown templates
|
|
458
305
|
- Use `tools/codex/rules/*.rules` for actual Codex approval-policy rules
|
|
459
306
|
- Use logical refs such as `@ai/instructions/WRITING.md` in tracked source
|
|
460
|
-
- Use `@builtin/facult-operating-model/...` for packaged
|
|
307
|
+
- Use `@builtin/facult-operating-model/...` for packaged built-in defaults
|
|
461
308
|
- Use `@project/...` when a tracked ref must resolve inside a repo-local `.ai`
|
|
462
309
|
- Use config-backed refs in prompts where you want stable named references such as `${refs.writing_rule}`
|
|
463
310
|
|
|
464
311
|
### Config and env layering
|
|
465
312
|
|
|
466
313
|
Canonical render context is layered explicitly:
|
|
467
|
-
1. built-ins injected by `
|
|
314
|
+
1. built-ins injected by `fclt`
|
|
468
315
|
2. active canonical root `config.toml`
|
|
469
316
|
3. active canonical root `config.local.toml`
|
|
470
317
|
4. explicit runtime overrides
|
|
@@ -480,10 +327,30 @@ Built-ins currently include:
|
|
|
480
327
|
Recommended split:
|
|
481
328
|
- `~/.ai/config.toml` or `<repo>/.ai/config.toml`: tracked, portable, non-secret refs/defaults
|
|
482
329
|
- `~/.ai/config.local.toml` or `<repo>/.ai/config.local.toml`: ignored, machine-local paths and secrets
|
|
330
|
+
- `~/.ai/mcp/servers.json` or `<repo>/.ai/mcp/servers.json`: tracked canonical MCP definitions
|
|
331
|
+
- `~/.ai/mcp/servers.local.json` or `<repo>/.ai/mcp/servers.local.json`: ignored machine-local MCP env overlay for secrets and per-machine auth
|
|
483
332
|
- `~/.ai/tools/<tool>/config.toml` or `<repo>/.ai/tools/<tool>/config.toml`: tracked tool defaults
|
|
484
333
|
- `~/.ai/tools/<tool>/config.local.toml` or `<repo>/.ai/tools/<tool>/config.local.toml`: ignored, machine-local tool overrides merged after tracked tool config during sync
|
|
485
334
|
- `[builtin].sync_defaults = false`: disable builtin default sync/materialization for this root
|
|
335
|
+
- `[project_sync.<tool>]`: explicit project-managed allowlist for assets that may render into repo-local tool outputs
|
|
486
336
|
- `fclt sync --builtin-conflicts overwrite`: allow packaged builtin defaults to overwrite locally modified generated targets
|
|
337
|
+
- `fclt audit fix ...`: move inline MCP secrets from tracked canonical config into the local MCP overlay and re-sync managed tool configs
|
|
338
|
+
|
|
339
|
+
For project-local `.ai` roots, tool sync is default-deny. Nothing flows into repo-local managed tool outputs unless the repo explicitly opts in. Use `config.toml` or `config.local.toml` under the project root:
|
|
340
|
+
|
|
341
|
+
```toml
|
|
342
|
+
version = 1
|
|
343
|
+
|
|
344
|
+
[project_sync.codex]
|
|
345
|
+
skills = ["hack-cli", "hack-tickets"]
|
|
346
|
+
agents = ["review-operator"]
|
|
347
|
+
mcp_servers = ["github"]
|
|
348
|
+
global_docs = true
|
|
349
|
+
tool_rules = true
|
|
350
|
+
tool_config = true
|
|
351
|
+
```
|
|
352
|
+
|
|
353
|
+
That policy applies to project-managed tool renders, including assets inherited from the merged global index. If you want a global skill inside a repo-local managed Codex output, name it explicitly here. `fclt doctor --repair` can materialize repo-local project assets into `config.local.toml` for already-managed project roots.
|
|
487
354
|
|
|
488
355
|
### Snippets
|
|
489
356
|
|
|
@@ -527,7 +394,7 @@ This is the explicit dependency layer for:
|
|
|
527
394
|
|
|
528
395
|
### Writeback and evolution
|
|
529
396
|
|
|
530
|
-
`
|
|
397
|
+
`fclt` also has a local writeback and evolution layer built on top of the graph:
|
|
531
398
|
|
|
532
399
|
```bash
|
|
533
400
|
fclt ai writeback add \
|
|
@@ -559,8 +426,8 @@ Runtime state stays generated and local inside the active canonical root:
|
|
|
559
426
|
|
|
560
427
|
That split is intentional:
|
|
561
428
|
- canonical source remains in `~/.ai` or `<repo>/.ai`
|
|
562
|
-
- writeback queues, journals, proposal records, trust state, autosync state, and other
|
|
563
|
-
- those records
|
|
429
|
+
- writeback queues, journals, proposal records, trust state, autosync state, and other generated runtime/config state stay inside `.ai/.facult/`
|
|
430
|
+
- those records let agents inspect what changed, why it changed, and how it was reviewed
|
|
564
431
|
|
|
565
432
|
Use writeback when:
|
|
566
433
|
- a task exposed a weak or misleading verification loop
|
|
@@ -568,15 +435,7 @@ Use writeback when:
|
|
|
568
435
|
- a pattern proved reusable enough to become doctrine
|
|
569
436
|
- a project-local pattern deserves promotion toward global capability
|
|
570
437
|
|
|
571
|
-
Do not think of writeback as
|
|
572
|
-
|
|
573
|
-
For many users, the normal entrypoint is not the CLI directly. The builtin operating-model layer is designed so synced agents, skills, and global docs can push the system toward writeback and evolution by default, while the `fclt ai ...` commands remain the explicit operator surface when you want direct control.
|
|
574
|
-
|
|
575
|
-
In other words:
|
|
576
|
-
- agents should be the ones noticing friction and capturing it
|
|
577
|
-
- skills should be the ones teaching when writeback or evolution is warranted
|
|
578
|
-
- proposal history should give future agents enough context to understand why a rule, instruction, or prompt changed
|
|
579
|
-
- you drop to the CLI when you want to inspect the thread, steer it, or make the final call
|
|
438
|
+
Do not think of writeback as note-taking. Treat it as preserved signal that should improve the system.
|
|
580
439
|
|
|
581
440
|
Current apply semantics are intentionally policy-bound:
|
|
582
441
|
- targets are resolved through the generated graph when possible and fall back to canonical ref resolution for missing assets
|
|
@@ -603,11 +462,19 @@ Most inventory and sync commands support explicit canonical-root selection:
|
|
|
603
462
|
|
|
604
463
|
## Security and Trust
|
|
605
464
|
|
|
606
|
-
`
|
|
465
|
+
`fclt` has two trust layers:
|
|
607
466
|
- Item trust: `fclt trust <name>` / `fclt untrust <name>`
|
|
608
467
|
- Source trust: `fclt sources ...` with levels `trusted`, `review`, `blocked`
|
|
609
468
|
|
|
610
|
-
|
|
469
|
+
Bulk trust annotations are also supported:
|
|
470
|
+
|
|
471
|
+
```bash
|
|
472
|
+
fclt trust --all
|
|
473
|
+
fclt trust skills --all
|
|
474
|
+
fclt untrust mcp --all
|
|
475
|
+
```
|
|
476
|
+
|
|
477
|
+
`fclt` also supports interactive and scripted audit flows:
|
|
611
478
|
|
|
612
479
|
1. Interactive audit workflow:
|
|
613
480
|
```bash
|
|
@@ -624,23 +491,23 @@ fclt audit --non-interactive --with claude --max-items 50
|
|
|
624
491
|
fclt audit --non-interactive --with codex --max-items all --json
|
|
625
492
|
```
|
|
626
493
|
|
|
494
|
+
4. Suppress or remediate reviewed findings:
|
|
495
|
+
```bash
|
|
496
|
+
fclt audit safe mcp:github --rule static:mcp-env-inline-secret --note "global managed render only"
|
|
497
|
+
fclt audit safe --all --source static --yes
|
|
498
|
+
fclt audit fix mcp:github
|
|
499
|
+
fclt audit fix --all --source combined --yes
|
|
500
|
+
```
|
|
501
|
+
|
|
627
502
|
Recommended security flow:
|
|
628
503
|
1. `fclt verify-source <source>`
|
|
629
504
|
2. `fclt sources trust <source>` only after review
|
|
630
505
|
3. use `--strict-source-trust` for `install`/`update`
|
|
631
|
-
4.
|
|
506
|
+
4. keep tracked canonical MCP config secret-free; use `mcp/servers.local.json` for machine-local secrets
|
|
507
|
+
5. run both static and agent audits on a schedule
|
|
632
508
|
|
|
633
509
|
## Comprehensive Reference
|
|
634
510
|
|
|
635
|
-
### Capability categories
|
|
636
|
-
|
|
637
|
-
- Inventory: discover local skills, MCP configs, hooks, and instruction files
|
|
638
|
-
- Management: consolidate, index, manage/unmanage tools, enable/disable entries, manage canonical AI config
|
|
639
|
-
- Security: static audit, agent audit, item trust, source trust, source verification
|
|
640
|
-
- Distribution: search/install/update from catalogs and verified manifests
|
|
641
|
-
- DX: scaffold templates and sync snippets into instruction/config files
|
|
642
|
-
- Automation: background autosync for local tool propagation and canonical repo git sync
|
|
643
|
-
|
|
644
511
|
### Command categories
|
|
645
512
|
|
|
646
513
|
- Inventory and discovery
|
|
@@ -668,6 +535,9 @@ fclt managed
|
|
|
668
535
|
fclt enable <name> [--for <tool1,tool2,...>]
|
|
669
536
|
fclt enable mcp:<name> [--for <tool1,tool2,...>]
|
|
670
537
|
fclt disable <name> [--for <tool1,tool2,...>]
|
|
538
|
+
fclt trust --all
|
|
539
|
+
fclt trust skills --all
|
|
540
|
+
fclt untrust mcp --all
|
|
671
541
|
fclt sync [tool] [--dry-run] [--builtin-conflicts overwrite]
|
|
672
542
|
fclt autosync install [tool] [--git-remote <name>] [--git-branch <name>] [--git-interval-minutes <n>] [--git-disable]
|
|
673
543
|
fclt autosync status [tool]
|
|
@@ -694,9 +564,9 @@ fclt templates list
|
|
|
694
564
|
fclt templates init project-ai
|
|
695
565
|
fclt templates init skill <name>
|
|
696
566
|
fclt templates init mcp <name>
|
|
567
|
+
fclt templates init agent <name>
|
|
697
568
|
fclt templates init snippet <marker>
|
|
698
569
|
fclt templates init agents
|
|
699
|
-
fclt templates init claude
|
|
700
570
|
fclt templates init automation <template-id> --scope global|project|wide [--name <name>] [--project-root <path>] [--cwds <path1,path2>] [--rrule <RRULE>] [--status PAUSED|ACTIVE]
|
|
701
571
|
|
|
702
572
|
fclt snippets list
|
|
@@ -779,7 +649,7 @@ fclt <command> --help
|
|
|
779
649
|
|
|
780
650
|
### Root resolution
|
|
781
651
|
|
|
782
|
-
`
|
|
652
|
+
`fclt` resolves the canonical root in this order:
|
|
783
653
|
1. `FACULT_ROOT_DIR`
|
|
784
654
|
2. nearest project `.ai` from the current working directory for CLI-facing commands
|
|
785
655
|
3. `~/.ai/.facult/config.json` (`rootDir`)
|
|
@@ -846,18 +716,6 @@ Default source aliases:
|
|
|
846
716
|
|
|
847
717
|
Custom remote sources can be defined in `~/.ai/.facult/indices.json` (manifest URL, optional integrity, optional signature keys/signature verification settings).
|
|
848
718
|
|
|
849
|
-
## Local Install Modes
|
|
850
|
-
|
|
851
|
-
For local CLI setup (outside npm global install), use:
|
|
852
|
-
|
|
853
|
-
```bash
|
|
854
|
-
bun run install:dev
|
|
855
|
-
bun run install:bin
|
|
856
|
-
bun run install:status
|
|
857
|
-
```
|
|
858
|
-
|
|
859
|
-
Default install path is `~/.ai/.facult/bin/fclt`. You can pass a custom target dir via `--dir=/path`.
|
|
860
|
-
|
|
861
719
|
## Autosync
|
|
862
720
|
|
|
863
721
|
`fclt autosync` is the background propagation layer for managed installs.
|
|
@@ -876,7 +734,7 @@ fclt autosync install
|
|
|
876
734
|
fclt autosync status
|
|
877
735
|
```
|
|
878
736
|
|
|
879
|
-
|
|
737
|
+
Tool-scoped or project-local usage:
|
|
880
738
|
|
|
881
739
|
```bash
|
|
882
740
|
cd /path/to/repo
|
|
@@ -884,12 +742,6 @@ fclt autosync install codex
|
|
|
884
742
|
fclt autosync status codex
|
|
885
743
|
```
|
|
886
744
|
|
|
887
|
-
Tool-scoped service:
|
|
888
|
-
|
|
889
|
-
```bash
|
|
890
|
-
fclt autosync install codex
|
|
891
|
-
```
|
|
892
|
-
|
|
893
745
|
One-shot runner for verification/debugging:
|
|
894
746
|
|
|
895
747
|
```bash
|
|
@@ -902,66 +754,19 @@ Remote git policy:
|
|
|
902
754
|
- on the configured timer, fetch, auto-commit local canonical changes if needed, pull `--rebase`, then push
|
|
903
755
|
- if rebase conflicts occur, remote autosync is blocked and reported, but local managed-tool sync keeps running
|
|
904
756
|
|
|
905
|
-
## CI and Release Automation
|
|
906
|
-
|
|
907
|
-
- CI workflow: `.github/workflows/ci.yml`
|
|
908
|
-
- Release workflow: `.github/workflows/release.yml`
|
|
909
|
-
- Semantic-release config: `.releaserc.json`
|
|
910
|
-
|
|
911
|
-
Release behavior:
|
|
912
|
-
1. Every push to `main` runs full checks.
|
|
913
|
-
2. `semantic-release` creates the version/tag and GitHub release (npm publish is disabled in this phase).
|
|
914
|
-
3. The same release workflow then builds platform binaries and uploads them to that GitHub release.
|
|
915
|
-
4. npm publish runs only after binary asset upload succeeds (`publish-npm` depends on `publish-assets`).
|
|
916
|
-
5. Published release assets include platform binaries, `fclt-install.sh`, `facult-install.sh`, and `SHA256SUMS`.
|
|
917
|
-
6. When `HOMEBREW_TAP_TOKEN` is configured, the release workflow also updates the Homebrew tap at `hack-dance/homebrew-tap`.
|
|
918
|
-
7. The npm package launcher resolves your platform, downloads the matching release binary, caches it under the machine-local cache root (`~/Library/Caches/fclt/runtime/...` on macOS or `${XDG_CACHE_HOME:-~/.cache}/fclt/runtime/...` elsewhere), and runs it.
|
|
919
|
-
|
|
920
|
-
Current prebuilt binary targets:
|
|
921
|
-
- `darwin-x64`
|
|
922
|
-
- `darwin-arm64`
|
|
923
|
-
- `linux-x64`
|
|
924
|
-
- `windows-x64`
|
|
925
|
-
|
|
926
|
-
Self-update behavior:
|
|
927
|
-
1. npm/bun global install: updates via package manager (`npm install -g facult@...` or `bun add -g facult@...`).
|
|
928
|
-
2. Direct binary install (release script/local binary path): downloads and replaces the binary in place.
|
|
929
|
-
3. Use `fclt self-update` (or `fclt update --self`).
|
|
930
|
-
|
|
931
|
-
Required secrets for publish:
|
|
932
|
-
- `NPM_TOKEN`
|
|
933
|
-
- `HOMEBREW_TAP_TOKEN` (fine-grained token with contents write access to `hack-dance/homebrew-tap`)
|
|
934
|
-
|
|
935
|
-
Local semantic-release dry-runs require a supported Node runtime (`>=24.10`).
|
|
936
|
-
|
|
937
|
-
Recommended one-time bootstrap before first auto release:
|
|
938
|
-
```bash
|
|
939
|
-
git tag v0.0.0
|
|
940
|
-
git push origin v0.0.0
|
|
941
|
-
```
|
|
942
|
-
|
|
943
|
-
This makes the first semantic-release increment land at `0.0.1` for patch-level changes.
|
|
944
|
-
|
|
945
757
|
## Commit Hygiene
|
|
946
758
|
|
|
947
759
|
Some MCP config files can contain secrets. Keep local generated artifacts and secret-bearing config files ignored and out of commits.
|
|
948
760
|
|
|
949
|
-
|
|
761
|
+
Recommended practice:
|
|
762
|
+
- tracked canonical MCP definitions in `mcp/servers.json` should not inline secrets
|
|
763
|
+
- machine-local secrets belong in `mcp/servers.local.json` or `mcp/mcp.local.json`
|
|
764
|
+
- global rendered configs under `~/.codex`, `~/.claude`, or similar can contain merged secret values as machine-local runtime output
|
|
765
|
+
- repo-local rendered configs should be gitignored; `fclt audit` now flags inline secrets more aggressively when the destination is git-tracked or repo-local and not ignored
|
|
950
766
|
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
bun run install:bin
|
|
955
|
-
bun run build
|
|
956
|
-
bun run build:verify
|
|
957
|
-
bun run type-check
|
|
958
|
-
bun run test:ci
|
|
959
|
-
bun test
|
|
960
|
-
bun run check
|
|
961
|
-
bun run fix
|
|
962
|
-
bun run pack:dry-run
|
|
963
|
-
bun run release:dry-run
|
|
964
|
-
```
|
|
767
|
+
## Contributing
|
|
768
|
+
|
|
769
|
+
Contributor and release workflow details live in [CONTRIBUTING.md](./CONTRIBUTING.md).
|
|
965
770
|
|
|
966
771
|
## FAQ
|
|
967
772
|
|
|
@@ -969,14 +774,17 @@ bun run release:dry-run
|
|
|
969
774
|
|
|
970
775
|
Not as a first-party `fclt mcp serve` runtime.
|
|
971
776
|
|
|
972
|
-
`
|
|
777
|
+
`fclt` currently focuses on inventory, trust/audit, install/update, and managed sync of canonical AI capability and tool-native outputs.
|
|
973
778
|
|
|
974
779
|
### Does fclt now manage global AI config, not just skills and MCP?
|
|
975
780
|
|
|
976
781
|
Yes. The core model now includes:
|
|
977
782
|
- canonical personal AI source in `~/.ai`
|
|
978
|
-
- rendered managed outputs in tool homes such as `~/.codex`
|
|
783
|
+
- rendered managed outputs in tool homes such as `~/.codex`, `~/.agents`, and `~/plugins`
|
|
979
784
|
- global instruction docs such as `AGENTS.global.md`, rendered by default into `~/.codex/AGENTS.md`, `~/.claude/CLAUDE.md`, and `~/.cursor/AGENTS.md`
|
|
785
|
+
- Codex-authored skills in `~/.agents/skills`
|
|
786
|
+
- Codex local plugin marketplaces in `~/.agents/plugins/marketplace.json`
|
|
787
|
+
- Codex local plugin bundles in `~/plugins/<plugin-name>`
|
|
980
788
|
- tool-native configs such as `~/.codex/config.toml`
|
|
981
789
|
- tool-native rule files such as `~/.codex/rules/*.rules`
|
|
982
790
|
|