feat(config): securely configure local Cartesia and OpenAI keys - #773
Draft
axelpey wants to merge 3 commits into
Draft
feat(config): securely configure local Cartesia and OpenAI keys#773axelpey wants to merge 3 commits into
axelpey wants to merge 3 commits into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Owners can now enter Cartesia and OpenAI keys through
innate keys set cartesia/innate keys set openai, inspect configuration presence withinnate keys status, and remove keys without putting credentials into browser settings, ROS parameters, command arguments, or output. Entry uses a hidden terminal prompt or a secret-manager pipe via--stdin; changes take effect after a node/local-simulator restart.The CLI reuses the simulator setup's
.envpersistence path. Updates are atomic, locked across processes, and mode 0600; replacing a key removes stale commented copies. Removal writes an empty override so old shell/system credentials do not silently return on restart. Generated simulator env files are also private and retain empty overrides. Local.envvalues now consistently take precedence over inherited shell keys, matching the robot launch loader.INNATE_PUBLIC_DEMO=1rejects key commands and credential-bearing generated environments.Runtime dependencies and boundaries
gpt-6-astra; entering a key does not select a model.Verification
50 focused tests passed: actual CLI subprocess save/rotate/status/remove, real PTY hidden input and cancellation, actual hardware
.envloader and simulator generated environment, service-key preservation, shell override removal, public-demo rejection, concurrent process writes, atomic failure cleanup, permissions, symlink refusal, and launcher imports. Ruff and diff checks pass. Latest head941d678f4passes GitHub format and host pytest; ROS integration/image builds are still pending.Combined verification against #755 plus #774 (
8e2d0d76a) and #772 (1cc44b47c) also passed: actual CLI pipe → private.env→ hardware launch loader → OpenAIContext two-turn native tool replay and Cartesia TTSHandler → local HTTP provider doubles, plus 54 provider/TTS tests. The integration needed two merge resolutions with #755: retain all fourSECRET_ENV_KEYSinsim/launcher/config.py, and retain David's generic setup UX while importing the extracted env-store helpers insetup_wizard.py. No foundation conflict occurred.The OpenAI transport's additional 8 real local HTTP tests passed before handoff to #772 (direct/proxy routing, no account failover, malformed/incomplete/error stream sanitization, missing key, public-demo guard). Live OpenAI account/model authorization and Cartesia synthesis with a non-owning key are not verified in this PR. Those require an owner-provided key through the local secret path; never paste credentials into a PR or chat.
Keep this PR draft until Axel explicitly approves it.