Skip to content

Commit 66c57d0

Browse files
committed
Merge remote-tracking branch 'origin/main' into fix/tool-output-defensiveness-and-duckdb-lock
# Conflicts: # packages/opencode/src/altimate/tools/schema-inspect.ts
2 parents 7293dd1 + d66354c commit 66c57d0

28 files changed

Lines changed: 3679 additions & 116 deletions

bun.lock

Lines changed: 36 additions & 9 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/docs/configure/warehouses.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -365,3 +365,16 @@ Testing connection to prod-snowflake (snowflake)...
365365
Warehouse: COMPUTE_WH
366366
Database: ANALYTICS
367367
```
368+
369+
## Post-Connection Suggestions
370+
371+
After you successfully connect a warehouse, altimate suggests next steps to help you get the most out of your connection. Suggestions are shown progressively based on what you've already done:
372+
373+
1. **Index your schemas** — populate the schema cache for autocomplete and context-aware analysis
374+
2. **Run SQL analysis** — scan your query history for anti-patterns and optimization opportunities
375+
3. **Inspect schema structure** — review tables, columns, and relationships
376+
4. **Check lineage** — trace column-level data flow across your models
377+
378+
If altimate detects a dbt project in your workspace, it also recommends relevant dbt skills (`/dbt-develop`, `/dbt-troubleshoot`, `/dbt-analyze`).
379+
380+
Each suggestion is shown **once per session** — dismissing or acting on a suggestion removes it from the queue. You can also run a suggested action later via its corresponding tool or slash command.

docs/docs/data-engineering/agent-modes.md

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,51 @@ altimate --agent plan
142142

143143
Plan mode restricts the agent to reading files and editing plan files only. No SQL, no bash, no file modifications. Use this to outline an approach before switching to builder to execute it.
144144

145+
### Two-step workflow
146+
147+
Plan mode uses a two-step approach to keep you in control:
148+
149+
1. **Outline** — The agent produces a short outline (3-5 bullet points) summarizing what it intends to do.
150+
2. **Expand** — After you confirm, the agent expands the outline into a full, detailed plan.
151+
152+
This prevents wasted effort on plans that are heading in the wrong direction.
153+
154+
### Refinement loop
155+
156+
You don't have to start over if the plan isn't quite right. After the agent presents its outline or full plan, you can:
157+
158+
- **Approve** — Accept the plan as-is (e.g., "looks good", "approved", "let's go").
159+
- **Refine** — Edit specific parts and ask the agent to revise (e.g., "change step 3 to use incremental instead of table").
160+
- **Reject** — Discard the plan entirely (e.g., "scrap this", "start over", "reject").
161+
162+
Refinements are capped at **5 revisions per session** to avoid endless loops. After the cap is reached, the agent asks you to approve or reject the current version.
163+
164+
### Example conversation
165+
166+
```
167+
You: Plan a migration of our raw_events table from a view to an incremental model
168+
169+
Plan: Here's my proposed approach:
170+
• Inspect the current raw_events view and its downstream dependencies
171+
• Design an incremental model with a timestamp-based strategy
172+
• Add schema tests for the new model
173+
• Create a cutover checklist for swapping the view to the model
174+
• Update the dbt DAG documentation
175+
176+
You: Change the second bullet — use insert_overwrite instead of timestamp-based
177+
178+
Plan: Updated outline:
179+
• Inspect the current raw_events view and its downstream dependencies
180+
• Design an incremental model with an insert_overwrite strategy
181+
• Add schema tests for the new model
182+
• Create a cutover checklist for swapping the view to the model
183+
• Update the dbt DAG documentation
184+
185+
You: Approved
186+
187+
Plan: [expands into a full detailed plan]
188+
```
189+
145190
---
146191

147192
## SQL Write Access Control

docs/docs/getting-started.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ Set up warehouse connections so altimate can query your data platform. You have
6060
4. **Offers to configure connections** and walks you through adding and testing each discovered warehouse
6161
5. **Indexes schemas** to populate the schema cache for autocomplete and context-aware analysis
6262

63-
Once complete, altimate indexes your schemas and detects your tooling, enabling schema-aware autocomplete and context-rich analysis.
63+
Once complete, altimate indexes your schemas and detects your tooling, enabling schema-aware autocomplete and context-rich analysis. After connecting, you'll see feature suggestions tailored to your warehouse type — such as indexing schemas, running SQL analysis, or checking lineage. These appear progressively and each is shown once per session. See [Post-Connection Suggestions](configure/warehouses.md#post-connection-suggestions) for details.
6464

6565
### Option B: Manual configuration
6666

docs/docs/reference/telemetry.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,9 @@ We collect the following categories of events:
3333
| `error_recovered` | Successful recovery from a transient error (error type, strategy, attempt count) |
3434
| `mcp_server_census` | MCP server capabilities after connect (tool and resource counts, but no tool names) |
3535
| `context_overflow_recovered` | Context overflow is handled (strategy) |
36-
| `skill_used` | A skill is loaded (skill name and source — `builtin`, `global`, or `project` — no skill content) |
36+
| `skill_used` | A skill is loaded (skill name, source — `builtin`, `global`, or `project`, and trigger — `user`, `auto`, or `suggestion` — no skill content) |
37+
| `plan_revision` | A plan revision occurs in Plan mode (revision_number, action: `refine`, `approve`, `reject`, or `cap_reached`) |
38+
| `feature_suggestion` | A post-connection feature suggestion is shown (suggestion_type, suggestions_shown, warehouse_type — no user input) |
3739
| `sql_execute_failure` | A SQL execution fails (warehouse type, query type, error message, PII-masked SQL — no raw values) |
3840
| `core_failure` | An internal tool error occurs (tool name, category, error class, truncated error message, PII-safe input signature, and optionally masked arguments — no raw values or credentials) |
3941
| `first_launch` | Fired once on first CLI run after installation. Contains version and is_upgrade flag. No PII. |

packages/drivers/package.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@
88
"./*": "./src/*.ts"
99
},
1010
"files": ["src"],
11+
"devDependencies": {
12+
"mongodb": "^6.0.0"
13+
},
1114
"optionalDependencies": {
1215
"pg": "^8.0.0",
1316
"snowflake-sdk": "^2.0.3",

packages/opencode/script/build.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -270,10 +270,12 @@ for (const item of targets) {
270270
})
271271

272272
// Create backward-compatible altimate-code alias
273+
// Use hard copy instead of symlink — npm publish and Docker COPY can strip symlinks,
274+
// causing "Binary not found" in Verdaccio sanity tests.
273275
if (item.os === "win32") {
274276
await $`cp dist/${name}/bin/altimate.exe dist/${name}/bin/altimate-code.exe`.nothrow()
275277
} else {
276-
await $`ln -sf altimate dist/${name}/bin/altimate-code`.nothrow()
278+
await $`cp dist/${name}/bin/altimate dist/${name}/bin/altimate-code`.nothrow()
277279
}
278280

279281
await $`rm -rf ./dist/${name}/bin/tui`

0 commit comments

Comments
 (0)