fix: clean Hermes CLI ATIF telemetry#101
Conversation
Signed-off-by: Bryan Bednarski <bbednarski@nvidia.com>
…missing ancestry on hook steps Signed-off-by: Bryan Bednarski <bbednarski@nvidia.com>
WalkthroughAdds support for Hermes ChangesHermes Hook Processing and ATIF Generation
🎯 3 (Moderate) | ⏱️ ~25 minutes Suggested labels: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@crates/cli/src/adapters/hermes.rs`:
- Around line 224-236: The hermes_exact_request function currently returns
Some(request) even when the extracted request is JSON null, causing
provider_payload_exact to be set for empty payloads; update hermes_exact_request
(which calls hermes_value_at and is_truncated_payload) to treat a null request
as non-exact by checking request.is_null() and returning None in that case
(i.e., only return Some(request) when the request is present, non-null, and not
truncated).
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Enterprise
Run ID: db74c87b-982d-418b-a70a-1a281d2b0221
📒 Files selected for processing (9)
crates/cli/src/adapters/hermes.rscrates/cli/src/adapters/mod.rscrates/cli/src/installer.rscrates/cli/src/session.rscrates/cli/tests/coverage/adapters_tests.rscrates/cli/tests/coverage/session_tests.rscrates/cli/tests/coverage/setup_tests.rscrates/core/src/observability/atif.rscrates/core/tests/unit/atif_tests.rs
📜 Review details
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: Check / Run
🧰 Additional context used
📓 Path-based instructions (12)
**/*.rs
📄 CodeRabbit inference engine (.agents/skills/test-ffi-surface/SKILL.md)
**/*.rs: Runcargo fmt --allfor FFI work as it is Rust work
Runjust test-rustfor FFI validation
Runcargo clippy --workspace --all-targets -- -D warningsto enforce warnings-as-errors linting
**/*.rs: Runcargo fmt --allfor Rust code formatting
Runcargo clippy --workspace --all-targets -- -D warningsto enforce Rust linting with no warnings
Runjust test-rustas the shared-runtime build/test wrapper for Rust changesUse Rust snake_case naming convention for Rust code
**/*.rs: Any Rust change must runjust test-rust
Any Rust change must runcargo fmt --all
Any Rust change must runcargo clippy --workspace --all-targets -- -D warnings
**/*.rs: Runcargo fmt --allfor Rust code formatting when Node changes touch Rust files
Runcargo clippy --workspace --all-targets -- -D warningsto enforce strict linting when Rust files changed as part of Node work
**/*.rs: Always runjust test-rustwhen any Rust code changes
Always runcargo fmt --allwhen any Rust code changes
Always runcargo clippy --workspace --all-targets -- -D warningswhen any Rust code changes
Files:
crates/cli/tests/coverage/setup_tests.rscrates/cli/src/installer.rscrates/cli/src/adapters/mod.rscrates/core/tests/unit/atif_tests.rscrates/cli/tests/coverage/session_tests.rscrates/core/src/observability/atif.rscrates/cli/src/session.rscrates/cli/tests/coverage/adapters_tests.rscrates/cli/src/adapters/hermes.rs
**/*.{rs,go,js,ts,tsx}
📄 CodeRabbit inference engine (CONTRIBUTING.md)
Include SPDX license headers in all Rust, Go, JavaScript, and TypeScript source files using C-style comment syntax
Files:
crates/cli/tests/coverage/setup_tests.rscrates/cli/src/installer.rscrates/cli/src/adapters/mod.rscrates/core/tests/unit/atif_tests.rscrates/cli/tests/coverage/session_tests.rscrates/core/src/observability/atif.rscrates/cli/src/session.rscrates/cli/tests/coverage/adapters_tests.rscrates/cli/src/adapters/hermes.rs
**/*.{rs,py,go,js,ts,tsx}
📄 CodeRabbit inference engine (CONTRIBUTING.md)
Use
SONAR_IGNORE_START/SONAR_IGNORE_ENDmarkers only for documented false positives that cannot be resolved in code; keep ignored blocks small, add explanatory comments, and require reviewer sign-off
Files:
crates/cli/tests/coverage/setup_tests.rscrates/cli/src/installer.rscrates/cli/src/adapters/mod.rscrates/core/tests/unit/atif_tests.rscrates/cli/tests/coverage/session_tests.rscrates/core/src/observability/atif.rscrates/cli/src/session.rscrates/cli/tests/coverage/adapters_tests.rscrates/cli/src/adapters/hermes.rs
**/*.{js,ts,tsx,jsx,py,rs,go,java,c,cpp,h,cc,cxx,cs,rb,php,swift,kt}
📄 CodeRabbit inference engine (.agents/skills/prepare-pr/SKILL.md)
Changed files must be formatted with the language-native formatter
Files:
crates/cli/tests/coverage/setup_tests.rscrates/cli/src/installer.rscrates/cli/src/adapters/mod.rscrates/core/tests/unit/atif_tests.rscrates/cli/tests/coverage/session_tests.rscrates/core/src/observability/atif.rscrates/cli/src/session.rscrates/cli/tests/coverage/adapters_tests.rscrates/cli/src/adapters/hermes.rs
**/*.{py,js,ts,tsx,go,rs,md}
📄 CodeRabbit inference engine (.agents/skills/validate-change/SKILL.md)
Format changed files with the language-native formatter before the final lint/test pass
Files:
crates/cli/tests/coverage/setup_tests.rscrates/cli/src/installer.rscrates/cli/src/adapters/mod.rscrates/core/tests/unit/atif_tests.rscrates/cli/tests/coverage/session_tests.rscrates/core/src/observability/atif.rscrates/cli/src/session.rscrates/cli/tests/coverage/adapters_tests.rscrates/cli/src/adapters/hermes.rs
**/*.{rs,py,js,ts,tsx,go}
📄 CodeRabbit inference engine (.agents/skills/validate-change/SKILL.md)
During iteration, prefer
uv run pre-commit run --files <changed files...>for targeted validation
Files:
crates/cli/tests/coverage/setup_tests.rscrates/cli/src/installer.rscrates/cli/src/adapters/mod.rscrates/core/tests/unit/atif_tests.rscrates/cli/tests/coverage/session_tests.rscrates/core/src/observability/atif.rscrates/cli/src/session.rscrates/cli/tests/coverage/adapters_tests.rscrates/cli/src/adapters/hermes.rs
{crates/**/tests/**,python/tests/**,go/nemo_flow/**/*_test.go}
⚙️ CodeRabbit configuration file
{crates/**/tests/**,python/tests/**,go/nemo_flow/**/*_test.go}: Tests should cover the behavior promised by the changed API surface, including error paths and cross-request isolation where relevant.
Prefer assertions on lifecycle events, scope stacks, middleware ordering, and binding parity over shallow smoke tests.
Files:
crates/cli/tests/coverage/setup_tests.rscrates/core/tests/unit/atif_tests.rscrates/cli/tests/coverage/session_tests.rscrates/cli/tests/coverage/adapters_tests.rs
crates/{core,adaptive}/**
📄 CodeRabbit inference engine (.agents/skills/prepare-pr/SKILL.md)
Changes to
crates/coreorcrates/adaptivemust run the full language matrix
Files:
crates/core/tests/unit/atif_tests.rscrates/core/src/observability/atif.rs
{crates/core,crates/adaptive}/**/*.rs
📄 CodeRabbit inference engine (.agents/skills/test-wasm-binding/SKILL.md)
If the change touched shared runtime semantics in
crates/coreorcrates/adaptive, also usevalidate-change
Files:
crates/core/tests/unit/atif_tests.rscrates/core/src/observability/atif.rs
crates/core/**/*.rs
📄 CodeRabbit inference engine (.agents/skills/validate-change/SKILL.md)
When
crates/corechanges, run the full validation matrix across Rust, Python, Go, Node.js, and WebAssembly
crates/core/**/*.rs: UseJson = serde_json::Valuein Rust-facing runtime APIs where the existing code expects JSON payloads.
UseResult<T>withFlowErrorin core runtime paths. Keep errors explicit and binding-appropriate at the wrapper layer.
Files:
crates/core/tests/unit/atif_tests.rscrates/core/src/observability/atif.rs
crates/{core,adaptive}/**/*.rs
⚙️ CodeRabbit configuration file
crates/{core,adaptive}/**/*.rs: Review the Rust runtime for async correctness, scope isolation, middleware ordering, and event lifecycle regressions.
Pay close attention to task-local/thread-local scope propagation, callback lifetimes, stream finalization, and root_uuid isolation.
Public API changes should preserve existing behavior unless tests and docs show the intended migration path.
Files:
crates/core/tests/unit/atif_tests.rscrates/core/src/observability/atif.rs
crates/core/src/observability/{atif,otel,openinference}.rs
📄 CodeRabbit inference engine (.agents/skills/maintain-observability/SKILL.md)
crates/core/src/observability/{atif,otel,openinference}.rs: When changing event fields, exporter behavior, subscriber config, or binding parity for ATIF, OpenTelemetry, or OpenInference, ensure the core event model and emitted fields remain in sync across ATIF (crates/core/src/observability/atif.rs), OpenTelemetry (crates/core/src/observability/otel.rs), and OpenInference (crates/core/src/observability/openinference.rs)
When event fields in observability exporters change, run the affected Rust crate tests plusjust test-rust
Files:
crates/core/src/observability/atif.rs
🔇 Additional comments (15)
crates/cli/src/installer.rs (1)
63-65: LGTM!crates/cli/src/adapters/mod.rs (1)
72-77: LGTM!Also applies to: 315-319
crates/core/src/observability/atif.rs (1)
943-977: LGTM!Also applies to: 1053-1053, 1061-1086
crates/core/tests/unit/atif_tests.rs (1)
54-57: LGTM!Also applies to: 626-701
crates/cli/src/adapters/hermes.rs (1)
41-64: LGTM!Also applies to: 66-222, 238-289
crates/cli/tests/coverage/setup_tests.rs (1)
335-335: LGTM!crates/cli/src/session.rs (1)
731-734: LGTM!crates/cli/tests/coverage/session_tests.rs (3)
361-442: LGTM!
444-497: LGTM!
498-540: LGTM!crates/cli/tests/coverage/adapters_tests.rs (5)
320-324: LGTM!
339-360: LGTM!
397-397: LGTM!
433-524: LGTM!
526-564: LGTM!
|
Before merge, we should also do the docs cleanup:
|
Signed-off-by: Bryan Bednarski <bbednarski@nvidia.com>
There was a problem hiding this comment.
Actionable comments posted: 1
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
crates/cli/tests/coverage/setup_tests.rs (1)
260-269: 🧹 Nitpick | 🔵 Trivial | ⚡ Quick winAlso assert
api_request_errorinhome_yamlforConfigScope::Both.The new hook key is only checked in
project_yaml; this test path writes both files.As per coding guidelines, "Tests should cover the behavior promised by the changed API surface, including error paths and cross-request isolation where relevant."Proposed test update
let home_yaml = std::fs::read_to_string(home.path().join(".hermes/config.yaml")).unwrap(); assert!(home_yaml.contains("nemo-flow hook-forward hermes")); + assert!(home_yaml.contains("api_request_error"));🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@crates/cli/tests/coverage/setup_tests.rs` around lines 260 - 269, The test currently asserts that project_yaml contains "api_request_error" but does not assert the same for home_yaml when ConfigScope::Both is exercised; update the test in crates/cli/tests/coverage/setup_tests.rs to add an assertion after reading home_yaml (the variable home_yaml) that it contains "api_request_error" (similar to the existing assert on project_yaml) so both config files are validated for the new hook key when ConfigScope::Both is used.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@crates/cli/tests/coverage/session_tests.rs`:
- Around line 41-49: The test helper read_atif_for_session is matching ATIF
files by doing trajectory.to_string().contains(session_id), which can select the
wrong file; change the selection to be deterministic by matching the filename
(entry.file_name() or entry.path().file_name()) against the known pattern
format!("trajectory-{}.json", session_id) or, alternatively, parse each JSON
Value and select the one whose session id field exactly equals session_id (e.g.,
value["session_id"] == session_id) so the function reliably returns the intended
ATIF file.
---
Outside diff comments:
In `@crates/cli/tests/coverage/setup_tests.rs`:
- Around line 260-269: The test currently asserts that project_yaml contains
"api_request_error" but does not assert the same for home_yaml when
ConfigScope::Both is exercised; update the test in
crates/cli/tests/coverage/setup_tests.rs to add an assertion after reading
home_yaml (the variable home_yaml) that it contains "api_request_error" (similar
to the existing assert on project_yaml) so both config files are validated for
the new hook key when ConfigScope::Both is used.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Enterprise
Run ID: 852543c4-cead-45bf-8b14-d1aac8967aaa
📒 Files selected for processing (4)
crates/cli/src/installer.rscrates/cli/src/session.rscrates/cli/tests/coverage/session_tests.rscrates/cli/tests/coverage/setup_tests.rs
📜 Review details
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: Check / Run
🧰 Additional context used
📓 Path-based instructions (7)
**/*.rs
📄 CodeRabbit inference engine (.agents/skills/test-ffi-surface/SKILL.md)
**/*.rs: Runcargo fmt --allfor FFI work as it is Rust work
Runjust test-rustfor FFI validation
Runcargo clippy --workspace --all-targets -- -D warningsto enforce warnings-as-errors linting
**/*.rs: Runcargo fmt --allfor Rust code formatting
Runcargo clippy --workspace --all-targets -- -D warningsto enforce Rust linting with no warnings
Runjust test-rustas the shared-runtime build/test wrapper for Rust changesUse Rust snake_case naming convention for Rust code
**/*.rs: Any Rust change must runjust test-rust
Any Rust change must runcargo fmt --all
Any Rust change must runcargo clippy --workspace --all-targets -- -D warnings
**/*.rs: Runcargo fmt --allfor Rust code formatting when Node changes touch Rust files
Runcargo clippy --workspace --all-targets -- -D warningsto enforce strict linting when Rust files changed as part of Node work
**/*.rs: Always runjust test-rustwhen any Rust code changes
Always runcargo fmt --allwhen any Rust code changes
Always runcargo clippy --workspace --all-targets -- -D warningswhen any Rust code changes
Files:
crates/cli/src/session.rscrates/cli/tests/coverage/setup_tests.rscrates/cli/src/installer.rscrates/cli/tests/coverage/session_tests.rs
**/*.{rs,go,js,ts,tsx}
📄 CodeRabbit inference engine (CONTRIBUTING.md)
Include SPDX license headers in all Rust, Go, JavaScript, and TypeScript source files using C-style comment syntax
Files:
crates/cli/src/session.rscrates/cli/tests/coverage/setup_tests.rscrates/cli/src/installer.rscrates/cli/tests/coverage/session_tests.rs
**/*.{rs,py,go,js,ts,tsx}
📄 CodeRabbit inference engine (CONTRIBUTING.md)
Use
SONAR_IGNORE_START/SONAR_IGNORE_ENDmarkers only for documented false positives that cannot be resolved in code; keep ignored blocks small, add explanatory comments, and require reviewer sign-off
Files:
crates/cli/src/session.rscrates/cli/tests/coverage/setup_tests.rscrates/cli/src/installer.rscrates/cli/tests/coverage/session_tests.rs
**/*.{js,ts,tsx,jsx,py,rs,go,java,c,cpp,h,cc,cxx,cs,rb,php,swift,kt}
📄 CodeRabbit inference engine (.agents/skills/prepare-pr/SKILL.md)
Changed files must be formatted with the language-native formatter
Files:
crates/cli/src/session.rscrates/cli/tests/coverage/setup_tests.rscrates/cli/src/installer.rscrates/cli/tests/coverage/session_tests.rs
**/*.{py,js,ts,tsx,go,rs,md}
📄 CodeRabbit inference engine (.agents/skills/validate-change/SKILL.md)
Format changed files with the language-native formatter before the final lint/test pass
Files:
crates/cli/src/session.rscrates/cli/tests/coverage/setup_tests.rscrates/cli/src/installer.rscrates/cli/tests/coverage/session_tests.rs
**/*.{rs,py,js,ts,tsx,go}
📄 CodeRabbit inference engine (.agents/skills/validate-change/SKILL.md)
During iteration, prefer
uv run pre-commit run --files <changed files...>for targeted validation
Files:
crates/cli/src/session.rscrates/cli/tests/coverage/setup_tests.rscrates/cli/src/installer.rscrates/cli/tests/coverage/session_tests.rs
{crates/**/tests/**,python/tests/**,go/nemo_flow/**/*_test.go}
⚙️ CodeRabbit configuration file
{crates/**/tests/**,python/tests/**,go/nemo_flow/**/*_test.go}: Tests should cover the behavior promised by the changed API surface, including error paths and cross-request isolation where relevant.
Prefer assertions on lifecycle events, scope stacks, middleware ordering, and binding parity over shallow smoke tests.
Files:
crates/cli/tests/coverage/setup_tests.rscrates/cli/tests/coverage/session_tests.rs
🔇 Additional comments (3)
crates/cli/src/installer.rs (1)
63-65: LGTM!crates/cli/src/session.rs (1)
657-660: LGTM!crates/cli/tests/coverage/session_tests.rs (1)
7-39: LGTM!Also applies to: 126-527
Signed-off-by: Bryan Bednarski <bbednarski@nvidia.com>
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@crates/cli/src/session.rs`:
- Around line 657-660: Remove the direct eprintln! used to report out-of-order
subagent end events in the event-handling code (the call that prints
event.event_name and event.subagent_id) and rely on the existing observability
call self.mark() to record the condition; if you prefer to keep printable
diagnostics, instead replace the eprintln! with a short comment explaining it is
intentional transient CLI diagnostic output (or add tracing::warn! only if you
add the tracing dependency), but do not leave an unannotated eprintln! in the
handler.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Enterprise
Run ID: 0b9e8807-2773-4ea7-99b9-c1546b0b69eb
📒 Files selected for processing (6)
crates/cli/src/adapters/hermes.rscrates/cli/src/session.rscrates/cli/tests/coverage/adapters_tests.rscrates/cli/tests/coverage/session_tests.rscrates/core/src/observability/atif.rsdocs/integrate-frameworks/coding-agent-hermes.md
📜 Review details
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (16)
- GitHub Check: WebAssembly / Test (macos-arm64)
- GitHub Check: Go / Test (windows-arm64)
- GitHub Check: WebAssembly / Test (windows-arm64)
- GitHub Check: WebAssembly / Test (linux-arm64)
- GitHub Check: WebAssembly / Test (windows-amd64)
- GitHub Check: Rust / Test (windows-arm64)
- GitHub Check: WebAssembly / Test (linux-amd64)
- GitHub Check: Go / Test (windows-amd64)
- GitHub Check: Rust / Test (windows-amd64)
- GitHub Check: Rust / Test (macos-arm64)
- GitHub Check: Python / Test (windows-amd64)
- GitHub Check: Node.js / Test (windows-arm64)
- GitHub Check: Node.js / Test (windows-amd64)
- GitHub Check: Python / Test (macos-arm64)
- GitHub Check: Python / Test (windows-arm64)
- GitHub Check: Documentation / Build
🧰 Additional context used
📓 Path-based instructions (31)
**/*.rs
📄 CodeRabbit inference engine (.agents/skills/test-ffi-surface/SKILL.md)
**/*.rs: Runcargo fmt --allfor FFI work as it is Rust work
Runjust test-rustfor FFI validation
Runcargo clippy --workspace --all-targets -- -D warningsto enforce warnings-as-errors linting
**/*.rs: Runcargo fmt --allfor Rust code formatting
Runcargo clippy --workspace --all-targets -- -D warningsto enforce Rust linting with no warnings
Runjust test-rustas the shared-runtime build/test wrapper for Rust changesUse Rust snake_case naming convention for Rust code
**/*.rs: Any Rust change must runjust test-rust
Any Rust change must runcargo fmt --all
Any Rust change must runcargo clippy --workspace --all-targets -- -D warnings
**/*.rs: Runcargo fmt --allfor Rust code formatting when Node changes touch Rust files
Runcargo clippy --workspace --all-targets -- -D warningsto enforce strict linting when Rust files changed as part of Node work
**/*.rs: Always runjust test-rustwhen any Rust code changes
Always runcargo fmt --allwhen any Rust code changes
Always runcargo clippy --workspace --all-targets -- -D warningswhen any Rust code changes
Files:
crates/cli/src/session.rscrates/cli/tests/coverage/session_tests.rscrates/cli/src/adapters/hermes.rscrates/cli/tests/coverage/adapters_tests.rscrates/core/src/observability/atif.rs
**/*.{rs,go,js,ts,tsx}
📄 CodeRabbit inference engine (CONTRIBUTING.md)
Include SPDX license headers in all Rust, Go, JavaScript, and TypeScript source files using C-style comment syntax
Files:
crates/cli/src/session.rscrates/cli/tests/coverage/session_tests.rscrates/cli/src/adapters/hermes.rscrates/cli/tests/coverage/adapters_tests.rscrates/core/src/observability/atif.rs
**/*.{rs,py,go,js,ts,tsx}
📄 CodeRabbit inference engine (CONTRIBUTING.md)
Use
SONAR_IGNORE_START/SONAR_IGNORE_ENDmarkers only for documented false positives that cannot be resolved in code; keep ignored blocks small, add explanatory comments, and require reviewer sign-off
Files:
crates/cli/src/session.rscrates/cli/tests/coverage/session_tests.rscrates/cli/src/adapters/hermes.rscrates/cli/tests/coverage/adapters_tests.rscrates/core/src/observability/atif.rs
**/*.{js,ts,tsx,jsx,py,rs,go,java,c,cpp,h,cc,cxx,cs,rb,php,swift,kt}
📄 CodeRabbit inference engine (.agents/skills/prepare-pr/SKILL.md)
Changed files must be formatted with the language-native formatter
Files:
crates/cli/src/session.rscrates/cli/tests/coverage/session_tests.rscrates/cli/src/adapters/hermes.rscrates/cli/tests/coverage/adapters_tests.rscrates/core/src/observability/atif.rs
**/*.{py,js,ts,tsx,go,rs,md}
📄 CodeRabbit inference engine (.agents/skills/validate-change/SKILL.md)
Format changed files with the language-native formatter before the final lint/test pass
Files:
crates/cli/src/session.rsdocs/integrate-frameworks/coding-agent-hermes.mdcrates/cli/tests/coverage/session_tests.rscrates/cli/src/adapters/hermes.rscrates/cli/tests/coverage/adapters_tests.rscrates/core/src/observability/atif.rs
**/*.{rs,py,js,ts,tsx,go}
📄 CodeRabbit inference engine (.agents/skills/validate-change/SKILL.md)
During iteration, prefer
uv run pre-commit run --files <changed files...>for targeted validation
Files:
crates/cli/src/session.rscrates/cli/tests/coverage/session_tests.rscrates/cli/src/adapters/hermes.rscrates/cli/tests/coverage/adapters_tests.rscrates/core/src/observability/atif.rs
**/*.{md,rst,html,txt}
📄 CodeRabbit inference engine (.agents/skills/review-doc-style/assets/nvidia-style-brand-terminology.md)
**/*.{md,rst,html,txt}: Always spellNVIDIAin all caps. Do not useNvidia,nvidia,nVidia,nVIDIA, orNV.
Usean NVIDIAbefore a noun because the name starts with an 'en' sound.
Do not add a registered trademark symbol afterNVIDIAwhen referring to the company.
Use trademark symbols with product names only when the document type or legal guidance requires them.
Verify official capitalization, spacing, and hyphenation for product names.
Precede NVIDIA product names withNVIDIAon first mention when it is natural and accurate.
Do not rewrite product names for grammar or title-case rules.
Preserve third-party product names according to the owner's spelling.
Include the company name and full model qualifier on first use when it helps identify the model.
Preserve the official capitalization and punctuation of model names.
Use shorter family names only after the full name is established.
Spell out a term on first use and put the acronym in parentheses unless the acronym is widely understood by the intended audience.
Use the acronym on later mentions after it has been defined.
For long documents, reintroduce the full term if readers might lose context.
Form plurals of acronyms withs, not an apostrophe, such asGPUs.
In headings, common acronyms can remain abbreviated. Spell out the term in the first or second sentence of the body.
Common terms such asCPU,GPU,PC,API, andUIusually do not need to be spelled out for developer audiences.
Files:
docs/integrate-frameworks/coding-agent-hermes.md
**/*.{md,rst,html}
📄 CodeRabbit inference engine (.agents/skills/review-doc-style/assets/nvidia-style-brand-terminology.md)
Link the first mention of a product name when the destination helps the reader.
Files:
docs/integrate-frameworks/coding-agent-hermes.md
**/*.{md,rst,txt}
📄 CodeRabbit inference engine (.agents/skills/review-doc-style/assets/nvidia-style-guide.md)
**/*.{md,rst,txt}: SpellNVIDIAin all caps. Do not useNvidia,nvidia, orNV.
Format commands, code elements, expressions, package names, file names, and paths as inline code.
Use descriptive link text. Avoid raw URLs and weak anchors such as 'here' or 'read more.'
Use title case consistently for technical documentation headings.
Introduce code blocks, lists, tables, and images with complete sentences.
Write procedures as imperative steps. Keep steps parallel and split long procedures into smaller tasks.
Prefer active voice, present tense, short sentences, contractions, and plain English.
Usecanfor possibility and reservemayfor permission.
Useafterfor temporal relationships instead ofonce.
Preferrefer tooverseewhen the wording points readers to another resource.
Avoid culture-specific idioms, unnecessary Latinisms, jokes, and marketing exaggeration in technical documentation.
Spell out months in body text, avoid ordinal dates, and use clear time zones.
Spell out whole numbers from zero through nine unless they are technical values, parameters, versions, or UI values.
Use numerals for 10 or greater and include commas in thousands.
Do not add trademark symbols to learning-oriented documentation unless the source, platform, or legal guidance explicitly requires them.
Do not add trademark symbols to NeMo Flow learning documentation by default.
Do not rewrite API names, package names, command flags, or code literals for style reasons.
Files:
docs/integrate-frameworks/coding-agent-hermes.md
**/*.{md,markdown,rst}
📄 CodeRabbit inference engine (.agents/skills/review-doc-style/assets/nvidia-style-technical-docs.md)
**/*.{md,markdown,rst}: Use title case consistently in technical documentation headings
Avoid quotation marks, ampersands, and exclamation marks in headings
Keep product, event, research, and whitepaper names in their official title case
Use title case for table headers
Do not force social-media sentence case into technical docs
Use monospace formatting for code elements, commands, parameters, package names, and expressions
Use monospace formatting for directories, file names, and paths
Use angle brackets inside monospace for variables inside paths, such as/home/<username>/.login
Use quotation marks for error messages and strings in documentation
Use bold formatting for UI buttons, menus, fields, and labels in documentation
Use angle brackets between UI labels for menu paths, such as File > Save As
Use italics for new terms on first use in documentation
Use italics for publication titles in documentation
Use plain text formatting for keyboard shortcuts in documentation
Prefer[NVIDIA/NeMo](link)format for GitHub repository references over generic phrases like 'the GitHub repo'
Introduce every code block with a complete sentence
Do not make a code block complete the grammar of the previous sentence
Do not continue a sentence after a code block
Use syntax highlighting when the format supports it for code blocks
Avoid the word 'snippet' unless the surrounding docs already use it as a term of art
Keep inline method, function, and class references consistent with nearby docs, omitting empty parentheses for prose readability when no call is shown
Use descriptive anchor text that matches the destination title when possible for links
Avoid raw URLs in running text in documentation
Avoid generic link anchors such as 'here,' 'this page,' and 'read more' in documentation
Include the acronym in link text if a linked term includes an acronym
Do not link long sentences or multiple sentences in documentation
Avoid links that pull readers away from a procedure unles...
Files:
docs/integrate-frameworks/coding-agent-hermes.md
**/*.{html,md}
📄 CodeRabbit inference engine (CONTRIBUTING.md)
Include SPDX license headers in HTML and Markdown files using HTML comment syntax
Files:
docs/integrate-frameworks/coding-agent-hermes.md
docs/**/*.md
📄 CodeRabbit inference engine (CONTRIBUTING.md)
Run
./scripts/build-docs.shfor documentation site changes
docs/**/*.md: Relevant getting-started or reference docs must be updated when examples change
Release-policy docs must point to GitHub Releases as the only release-history source of truth
docs/**/*.md: Use title case for headings in technical documentation
Introduce code blocks, tables, and lists with complete lead-in sentences in documentation
Files:
docs/integrate-frameworks/coding-agent-hermes.md
**/*.md
📄 CodeRabbit inference engine (CONTRIBUTING.md)
Run Markdown link checking via
lycheeforREADME.md,CONTRIBUTING.md, anddocs/through pre-commit hooks
Files:
docs/integrate-frameworks/coding-agent-hermes.md
**/*.{md,markdown,py,sh,bash,js,ts,java,cpp,go,rust}
📄 CodeRabbit inference engine (.agents/skills/contribute-docs/SKILL.md)
Keep package names, repo references, and build commands current in documentation
Files:
docs/integrate-frameworks/coding-agent-hermes.md
{RELEASING.md,CHANGELOG.md,docs/**/*.md}
📄 CodeRabbit inference engine (.agents/skills/contribute-docs/SKILL.md)
Keep release-process and release-notes guidance in repo-maintainer docs such as RELEASING.md, not as user-facing docs pages or CHANGELOG.md
Files:
docs/integrate-frameworks/coding-agent-hermes.md
**/*.{md,markdown,py,sh,bash}
📄 CodeRabbit inference engine (.agents/skills/contribute-docs/SKILL.md)
Keep stable user-facing wrappers at scripts/ root in docs and examples; only point at namespaced helper paths when documenting internal maintenance work
Files:
docs/integrate-frameworks/coding-agent-hermes.md
**/*.{md,markdown,py,sh,bash,js,ts,example}
📄 CodeRabbit inference engine (.agents/skills/contribute-docs/SKILL.md)
Example commands must match current package names and paths
Files:
docs/integrate-frameworks/coding-agent-hermes.md
docs/integrate-frameworks/**/*.md
📄 CodeRabbit inference engine (.agents/skills/contribute-integration/SKILL.md)
Documentation must be updated if activation or usage of the integration changed
Files:
docs/integrate-frameworks/coding-agent-hermes.md
{scripts/*.sh,docs/**/*.md}
📄 CodeRabbit inference engine (.agents/skills/contribute-integration/SKILL.md)
Use root
./scripts/*.shcommands in docs and contributor guidance as documented, with implementations underscripts/third-party/
Files:
docs/integrate-frameworks/coding-agent-hermes.md
{docs/**,examples/**,crates/adaptive/**,python/nemo_flow/**,go/nemo_flow/**,**/{example,component}.{ts,tsx,js,rs,py,go}}
📄 CodeRabbit inference engine (.agents/skills/maintain-optimizer/SKILL.md)
Any new adaptive component kind must have documentation, examples, and binding coverage across all supported languages
Files:
docs/integrate-frameworks/coding-agent-hermes.md
{README*,CHANGELOG*,docs/**/*.{md,rst,txt},examples/**/*,*.md}
📄 CodeRabbit inference engine (.agents/skills/rename-surfaces/SKILL.md)
Update documentation, examples, and getting-started guides with new package/module/crate names after rename operations
Files:
docs/integrate-frameworks/coding-agent-hermes.md
**/*.{md,txt,rst}
📄 CodeRabbit inference engine (.agents/skills/review-doc-style/SKILL.md)
**/*.{md,txt,rst}: Ensure commands, package names, file paths, and APIs in documentation are correct and not stale; flag incorrect or outdated information as blocking issues
Ensure examples and procedures in documentation will execute successfully with current APIs and commands
Use consistent user-facing terminology throughout documentation that matches current repo terminology
Capitalize NVIDIA correctly in all documentation and public-facing text
Format code, commands, paths, and filenames as inline code (monospace) in documentation
Use descriptive anchor text for links instead of bare URLs or weak labels like 'here' in documentation
Prefer active voice, present tense, short sentences, and plain English in documentation
Structure documentation procedures as imperative steps that are easy to scan and not too long for a single sequence
Prefer 'after' instead of 'once' for temporal references in documentation
Use 'can' instead of 'may' when describing possibility (rather than permission) in documentation
Avoid ambiguous numeric dates and ordinal dates in documentation body text
Files:
docs/integrate-frameworks/coding-agent-hermes.md
{README.md,docs/**/*.md,examples/**/*.{js,ts,py,go,rs}}
📄 CodeRabbit inference engine (.agents/skills/maintain-packaging/SKILL.md)
Keep documentation and examples synchronized with current install, import, and build commands
Files:
docs/integrate-frameworks/coding-agent-hermes.md
{README.md,CONTRIBUTING.md,docs/**/*.md}
📄 CodeRabbit inference engine (.agents/skills/validate-change/SKILL.md)
For docs-only changes, run targeted checks only if commands, package names, or examples changed. Use
just docsfor docs-site builds andjust docs-linkcheckwhen links changed
Files:
docs/integrate-frameworks/coding-agent-hermes.md
{docs/**,README.md,CONTRIBUTING.md,RELEASING.md,SECURITY.md}
⚙️ CodeRabbit configuration file
{docs/**,README.md,CONTRIBUTING.md,RELEASING.md,SECURITY.md}: Review documentation for technical accuracy against the current API, command correctness, and consistency across language bindings.
Flag stale examples, missing SPDX headers where required, and instructions that no longer match CI or pre-commit behavior.
Files:
docs/integrate-frameworks/coding-agent-hermes.md
{crates/**/tests/**,python/tests/**,go/nemo_flow/**/*_test.go}
⚙️ CodeRabbit configuration file
{crates/**/tests/**,python/tests/**,go/nemo_flow/**/*_test.go}: Tests should cover the behavior promised by the changed API surface, including error paths and cross-request isolation where relevant.
Prefer assertions on lifecycle events, scope stacks, middleware ordering, and binding parity over shallow smoke tests.
Files:
crates/cli/tests/coverage/session_tests.rscrates/cli/tests/coverage/adapters_tests.rs
crates/core/src/observability/{atif,otel,openinference}.rs
📄 CodeRabbit inference engine (.agents/skills/maintain-observability/SKILL.md)
crates/core/src/observability/{atif,otel,openinference}.rs: When changing event fields, exporter behavior, subscriber config, or binding parity for ATIF, OpenTelemetry, or OpenInference, ensure the core event model and emitted fields remain in sync across ATIF (crates/core/src/observability/atif.rs), OpenTelemetry (crates/core/src/observability/otel.rs), and OpenInference (crates/core/src/observability/openinference.rs)
When event fields in observability exporters change, run the affected Rust crate tests plusjust test-rust
Files:
crates/core/src/observability/atif.rs
crates/{core,adaptive}/**
📄 CodeRabbit inference engine (.agents/skills/prepare-pr/SKILL.md)
Changes to
crates/coreorcrates/adaptivemust run the full language matrix
Files:
crates/core/src/observability/atif.rs
{crates/core,crates/adaptive}/**/*.rs
📄 CodeRabbit inference engine (.agents/skills/test-wasm-binding/SKILL.md)
If the change touched shared runtime semantics in
crates/coreorcrates/adaptive, also usevalidate-change
Files:
crates/core/src/observability/atif.rs
crates/core/**/*.rs
📄 CodeRabbit inference engine (.agents/skills/validate-change/SKILL.md)
When
crates/corechanges, run the full validation matrix across Rust, Python, Go, Node.js, and WebAssembly
crates/core/**/*.rs: UseJson = serde_json::Valuein Rust-facing runtime APIs where the existing code expects JSON payloads.
UseResult<T>withFlowErrorin core runtime paths. Keep errors explicit and binding-appropriate at the wrapper layer.
Files:
crates/core/src/observability/atif.rs
crates/{core,adaptive}/**/*.rs
⚙️ CodeRabbit configuration file
crates/{core,adaptive}/**/*.rs: Review the Rust runtime for async correctness, scope isolation, middleware ordering, and event lifecycle regressions.
Pay close attention to task-local/thread-local scope propagation, callback lifetimes, stream finalization, and root_uuid isolation.
Public API changes should preserve existing behavior unless tests and docs show the intended migration path.
Files:
crates/core/src/observability/atif.rs
🔇 Additional comments (5)
crates/core/src/observability/atif.rs (1)
943-977: LGTM!Also applies to: 1053-1053, 1061-1094
crates/cli/src/adapters/hermes.rs (1)
41-64: LGTM!Also applies to: 93-106, 121-138, 170-205, 207-289
crates/cli/tests/coverage/session_tests.rs (1)
7-67: LGTM!Also applies to: 143-543
crates/cli/tests/coverage/adapters_tests.rs (1)
320-324: LGTM!Also applies to: 339-360, 397-397, 433-596
docs/integrate-frameworks/coding-agent-hermes.md (1)
123-123: LGTM!Also applies to: 129-133
|
/merge |
Overview
This PR cleans up ATIF trajectories produced by end-to-end Hermes sessions through the NeMo Flow CLI. It removes noisy hook-only system rows, preserves useful hook context when Hermes emits sparse payloads, adds ancestry for hook-derived ATIF system steps, and avoids trailing empty ATIF steps at session boundaries.
Details
on_session_endas a per-turn snapshot signal only. It now emitsTurnEndedwithout also creating a user-visibleHookMarksystem step.extrapayload fields.subagent_stopevidence as a readablesubagent_end_without_startATIF mark and emit a warning when no matchingsubagent_startwas observed.hook_event_name, ancestry, and invocation information.{}system steps.Validation run:
Where should the reviewer start?
Start with
crates/core/src/observability/atif.rs. The central design decision is that ATIF mark steps should remain useful system evidence, but empty marks should be dropped and non-empty marks should carry hook identity plus ancestry.Then review
crates/cli/src/adapters/hermes.rsfor the Hermes-specificon_session_endbehavior, andcrates/cli/tests/coverage/session_tests.rsfor the end-to-end sidecar regression cases.Related Issues: (use one of the action keywords Closes / Fixes / Resolves / Relates to)
Summary by CodeRabbit
New Features
Bug Fixes
Tests
Documentation