Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
5118134
fix(security): char-safe truncation in sanitize_system_prompt Fixes #…
May 19, 2026
f490a41
trigger: rebuild after repo cleanup
May 19, 2026
7218d53
fix(clippy): remaining field-reassign-with-default and unnecessary ca…
May 19, 2026
952b7e4
trigger: rebuild with clean repo
May 19, 2026
9dee7d0
trigger: rebuild webhook test
May 19, 2026
2d66e2c
trigger: full-clone pipeline test Refs #1721
May 19, 2026
5958b2a
trigger: pipeline test with full clone Refs #1721
May 19, 2026
b58044f
trigger: depth=1 fetch pipeline test Refs #1721
May 19, 2026
b0b43dd
ci: e2e pipeline test from local Refs #1721
May 19, 2026
83c114d
ci: selective refspec pipeline test Refs #1721
May 19, 2026
58c6a57
ci: final pipeline test with webhook ready Refs #1721
May 19, 2026
f65d8b9
style: cargo fmt for role_llm_api_key test Refs #1721
May 19, 2026
bdd1156
fix: remove accidentally committed project.rs Refs #1721
May 19, 2026
85b19a5
ci: fresh clone pipeline test Refs #1721
May 19, 2026
0b1ebf9
fix(build-runner): tee output to file and fix BUILD.md parsing
May 19, 2026
26f5b87
feat(config): implement project-level config discovery for .terraphim/
May 19, 2026
59cd233
feat(config): implement project-level config discovery for .terraphim/
May 19, 2026
82c7467
fix(config): remove needless borrows in project.rs clippy warnings
May 19, 2026
af9f0f5
Merge remote-tracking branch 'origin/push-1721' into push-1721
May 19, 2026
64136b2
docs: update project-level config discovery documentation
May 19, 2026
6fea5ad
fix(security): char-safe truncation in sanitize_system_prompt and bui…
May 19, 2026
9a4a83a
docs: add release announcement for v2026.05.19
May 19, 2026
2f3ada1
Merge remote-tracking branch 'origin/push-1721' into push-1721
May 19, 2026
b409960
chore: bump version to 1.19.1 for release
May 19, 2026
ed20d3b
chore: bump version to 1.19.2
May 19, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
55 changes: 55 additions & 0 deletions .docs/releases/v2026.05.19.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
# Release v2026.05.19

**Date:** 2026-05-19
**Author:** Alex

## Highlights

### Project-Level Config Discovery for terraphim-agent

This release introduces project-level configuration support for `terraphim-agent`, enabling developers to define project-specific roles, global shortcuts, and configuration overrides in a `.terraphim/config.json` file within their project directories.

**Key Features:**
- **Automatic Discovery**: Searches parent directories for `.terraphim/` directory starting from current working directory
- **Role Merging**: Project-specific roles override global roles by `RoleName` (full replacement, not deep merge)
- **Global Shortcut**: Optional `global_shortcut` field allows project configs to omit it
- **Non-Invasive**: Global config remains unchanged; project config is optional

**Usage:**
```json
{
"global_shortcut": "Cmd+K",
"roles": {
"MyProjectRole": {
"haystacks": ["/path/to/project/docs"],
...
}
}
}
```

### Security Fix

- **fix(security): char-safe truncation in sanitize_system_prompt** (Fixes #1721)

### Build Improvements

- **fix(build-runner): tee output to file and fix BUILD.md parsing**

## Full Changelog

| Commit | Description |
|--------|-------------|
| `59cd233b7` | feat(config): implement project-level config discovery for .terraphim/ |
| `26f5b8728` | feat(config): implement project-level config discovery for .terraphim/ |
| `82c746757` | fix(config): remove needless borrows in project.rs clippy warnings |
| `511813479` | fix(security): char-safe truncation in sanitize_system_prompt Fixes #1721 |
| `0b1ebf9d2` | fix(build-runner): tee output to file and fix BUILD.md parsing |

## Upgrade Notes

No breaking changes. Project-level config is entirely optional and backward-compatible with existing global configurations.

## Related Issues

- #1721 - Security: UTF-8 boundary panic in sanitize_system_prompt
7 changes: 7 additions & 0 deletions .docs/summary-crates-terraphim_config-src-lib.rs.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,13 @@
2. Saved config retrieved from persistence layer
3. Hard-coded defaults in `terraphim_server/default/`

**Project-Level Config Discovery:**
- Searches parent directories for `.terraphim/` directory starting from current working directory
- Enables project-specific roles, global shortcuts, and configuration overrides
- Merged with global config via `Config::with_project()` and `Config::merge_with()`
- Roles merged by `RoleName`: project role fully replaces global role (no deep merge)
- `global_shortcut` field is optional in project configs

**Key Types:**
- **`Config`**: Top-level configuration holding all roles, global shortcut, default/selected role
- **`Role`**: User profile with haystacks, relevance function, theme, LLM settings
Expand Down
8 changes: 8 additions & 0 deletions .docs/summary.md
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,14 @@ User Query
- `Role`: User profile with haystacks, relevance function, theme, LLM settings
- `Haystack`: Data source descriptor with service type
- `KnowledgeGraph`: Automata path and/or local KG files
- `ProjectConfig`: Project-level overrides in `.terraphim/config.json`

**Project-Level Config Discovery:**
- Searches parent directories for `.terraphim/` directory starting from CWD
- Enables project-specific roles, global shortcuts, and configuration overrides
- Merged with global config via `Config::with_project()` and `Config::merge_with()`
- Roles merged by `RoleName`: project role fully replaces global role
- Optional `global_shortcut` field allows project configs to omit it

**Service Types Supported:**
- Ripgrep, Atomic Server, QueryRs, ClickUp, MCP, Perplexity, GrepApp, AiAssistant, Quickwit, JMAP
Expand Down
52 changes: 26 additions & 26 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ exclude = [
default-members = ["terraphim_server"]

[workspace.package]
version = "1.17.1"
version = "1.19.2"
edition = "2024"

[workspace.dependencies]
Expand Down
2 changes: 1 addition & 1 deletion crates/haystack_grepapp/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ license = "MIT"
repository = "https://github.com/terraphim/terraphim-ai"

[dependencies]
haystack_core = { path = "../haystack_core", version = "1.0.0" }
haystack_core = { path = "../haystack_core", version = "1.19.2" }
terraphim_types = { path = "../terraphim_types", version = "1.0.0" }
reqwest = { workspace = true, features = ["json", "rustls-tls"] }

Expand Down
2 changes: 1 addition & 1 deletion crates/haystack_jmap/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "haystack_jmap"
version = "1.0.0"
version = "1.19.2"
edition.workspace = true
license = "MIT"

Expand Down
2 changes: 1 addition & 1 deletion crates/terraphim-markdown-parser/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "terraphim-markdown-parser"
version = "1.0.0"
version = "1.19.2"
edition.workspace = true
authors = ["Terraphim Contributors"]
description = "Terraphim Markdown Parser"
Expand Down
2 changes: 1 addition & 1 deletion crates/terraphim-session-analyzer/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ tracing = { workspace = true }
tracing-subscriber = { version = "0.3", features = ["env-filter"] }

# Feature-gated Terraphim dependencies (sibling crates in workspace)
terraphim_automata = { path = "../terraphim_automata", version = "1.0.0", optional = true }
terraphim_automata = { path = "../terraphim_automata", version = "1.19.2", optional = true }
terraphim_types = { path = "../terraphim_types", version = "1.0.0", optional = true }
terraphim_config = { path = "../terraphim_config", version = "1.0.0", optional = true }

Expand Down
2 changes: 1 addition & 1 deletion crates/terraphim_agent/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ terraphim_types = { path = "../terraphim_types", version = "1.0.0" }
terraphim_settings = { path = "../terraphim_settings", version = "1.0.0" }
terraphim_persistence = { path = "../terraphim_persistence", version = "1.0.0" }
terraphim_config = { path = "../terraphim_config", version = "1.0.0" }
terraphim_automata = { path = "../terraphim_automata", version = "1.0.0" }
terraphim_automata = { path = "../terraphim_automata", version = "1.19.2" }
terraphim_service = { path = "../terraphim_service", version = "1.0.0", default-features = false }
terraphim_middleware = { path = "../terraphim_middleware", version = "1.0.0" }
terraphim_rolegraph = { path = "../terraphim_rolegraph", version = "1.0.0" }
Expand Down
4 changes: 2 additions & 2 deletions crates/terraphim_agent/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2049,7 +2049,7 @@ async fn run_offline_command(
return run_learn_command(sub).await;
}

let service = TuiService::new(config_path).await?;
let service = TuiService::new(config_path, false).await?;

match command {
Command::Search {
Expand Down Expand Up @@ -5087,7 +5087,7 @@ fn ui_loop(

#[cfg(not(feature = "server"))]
let backend = {
let service = rt.block_on(async { TuiService::new(None).await })?;
let service = rt.block_on(async { TuiService::new(None, false).await })?;
crate::tui_backend::TuiBackend::Local(service)
};

Expand Down
2 changes: 1 addition & 1 deletion crates/terraphim_agent/src/repl/handler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2882,7 +2882,7 @@ impl ReplHandler {

/// Run REPL in offline mode
pub async fn run_repl_offline_mode() -> Result<()> {
let service = TuiService::new(None).await?;
let service = TuiService::new(None, false).await?;
let mut handler = ReplHandler::new_offline(service);
handler.run().await
}
Expand Down
Loading
Loading