A retro-futuristic control surface for manipulating AI cognition in real-time.
Transform LLM interaction from prompt engineering to parameter manipulation. Instead of crafting prompts, adjust cognitive dimensions with analog-style controls and see results at frame-rate speed.
- Real-time Parameter Control: Adjust temperature, max tokens, top-p, frequency penalty, and presence penalty with tactile slider controls
- Live Preview Mode: Ultra-fast inference (<100ms) enables continuous feedback as you adjust parameters
- Configuration Management: Save and load parameter presets for different use cases
- Distinctive Retro Design: Vintage studio equipment aesthetic with warm amber LEDs, wood tones, and metallic finishes
- Debounced Processing: Smart request handling prevents overwhelming the API
- Request Cancellation: Outdated requests are automatically cancelled
Inspired by 1970s analog synthesizers and mixing consoles, Cognitive Knobs makes abstract AI parameters feel tangible and manipulable. The interface features:
- Warm color palette (amber, copper, brass, wood tones)
- LED-style readouts and VU meters
- Analog fader controls
- Grain textures and metallic finishes
- Distinctive typography (Orbitron, Space Mono, Major Mono Display)
- Node.js 18+
- OpenRouter API key (get one here)
-
Configure environment variables:
Edit
.envand add your OpenRouter API key:OPENROUTER_API_KEY=your-api-key-here
-
Update the model (important!):
Open
src/routes/api/generate/+server.tsand update theCEREBRAS_MODELconstant with the correct Cerebras GLM 4.6 model identifier from OpenRouter.Check OpenRouter's model list for the exact Cerebras GLM 4.6 model name.
-
Start the development server:
npm run dev
-
Open your browser: Navigate to the URL shown in terminal (e.g.,
http://localhost:5174)
- Set System Prompt: Define how the AI should behave
- Adjust Cognitive Parameters: Use the sliders to manipulate cognitive dimensions
- Enter Input: Type your text to transform
- Generate: Click generate or enable live preview mode
Toggle "Live Preview" to enable real-time processing. As you adjust parameters, the output updates automatically (with 300ms debouncing).
- Click Presets to expand configuration manager
- Enter a name for your current settings
- Click Save
- Load saved presets anytime to quickly switch configurations
- Framework: SvelteKit 2 + Svelte 5 (with runes)
- Language: TypeScript
- API: OpenRouter (Cerebras GLM 4.6)
- Styling: Custom CSS with CSS variables
- State Management: Svelte 5 runes ($state, $derived, $effect)
MIT
Made with ⚡ using Claude Code