t1code-terminal-ui
```markdown
What this skill does
```markdown
---
name: t1code-terminal-ui
description: AI-powered terminal coding assistant (T3Code in your terminal) using OpenTUI
triggers:
- "use t1code in my terminal"
- "run t1code TUI"
- "set up terminal AI coding assistant"
- "t1code configuration"
- "bunx t1code"
- "T3Code terminal version"
- "t1code LLM coding TUI"
- "install t1code globally"
---
# t1code Terminal UI Skill
> Skill by [ara.so](https://ara.so) — Daily 2026 Skills collection.
## What is t1code?
t1code is a terminal user interface (TUI) for AI-assisted coding, inspired by T3Code (by @t3dotgg and @juliusmarminge). It brings an LLM-powered coding assistant directly into your terminal using the OpenTUI framework. It supports models via API (similar to Codex/Claude/OpenAI-compatible endpoints) and runs entirely in the terminal.
---
## Installation
### Run instantly (no install)
```bash
bunx @maria_rcks/t1code
```
### Install globally
```bash
bun add -g @maria_rcks/t1code
```
After global install, run with:
```bash
t1code
```
### Develop from source
```bash
git clone https://github.com/maria-rcks/t1code.git
cd t1code
bun install
bun dev:tui
```
---
## Requirements
- [Bun](https://bun.sh) runtime (v1.x+)
- A terminal that supports ANSI escape codes
- An LLM API key (OpenAI-compatible endpoint recommended)
---
## Key Commands
| Command | Description |
|---|---|
| `bunx @maria_rcks/t1code` | Run t1code without installing |
| `bun add -g @maria_rcks/t1code` | Install globally |
| `t1code` | Launch TUI (if globally installed) |
| `bun dev:tui` | Run in dev mode from source |
| `bun install` | Install dependencies from source |
---
## Configuration
t1code uses environment variables for API keys and model configuration. Set these before running:
```bash
# OpenAI-compatible API key
export OPENAI_API_KEY=your_api_key_here
# Optional: custom base URL for OpenAI-compatible APIs (e.g. local Ollama, Together, etc.)
export OPENAI_BASE_URL=https://api.openai.com/v1
# Optional: specify default model
export OPENAI_MODEL=gpt-4o
```
You can place these in a `.env` file in the project root when developing from source:
```env
OPENAI_API_KEY=your_api_key_here
OPENAI_BASE_URL=https://api.openai.com/v1
OPENAI_MODEL=gpt-4o
```
---
## TUI Navigation
Once launched, t1code presents a terminal UI with:
- **Chat/prompt input** — Type your coding question or instruction
- **Code output panel** — Displays AI-generated code with syntax highlighting
- **Keyboard shortcuts** — Navigate panels, copy output, clear history
Common TUI interactions:
| Key | Action |
|---|---|
| `Enter` | Submit prompt |
| `Ctrl+C` | Exit t1code |
| `Tab` | Switch focus between panels |
| `Ctrl+L` | Clear the chat/output |
| Arrow keys | Scroll through output |
---
## Development: Project Structure
```
t1code/
├── src/
│ ├── tui/ # OpenTUI components and layout
│ ├── llm/ # LLM API client logic
│ ├── config/ # Configuration loading
│ └── index.ts # Entry point
├── assets/
│ └── repo/
├── package.json
└── bun.lockb
```
---
## Real Code Examples
### Running t1code programmatically (from source entry point)
```typescript
// src/index.ts - typical entry pattern
import { startTUI } from "./tui";
import { loadConfig } from "./config";
const config = loadConfig();
await startTUI(config);
```
### Extending the LLM client (OpenAI-compatible)
```typescript
// src/llm/client.ts - example OpenAI-compatible fetch
const response = await fetch(`${process.env.OPENAI_BASE_URL}/chat/completions`, {
method: "POST",
headers: {
"Content-Type": "application/json",
Authorization: `Bearer ${process.env.OPENAI_API_KEY}`,
},
body: JSON.stringify({
model: process.env.OPENAI_MODEL ?? "gpt-4o",
messages: [
{ role: "system", content: "You are a helpful coding assistant." },
{ role: "user", content: userPrompt },
],
stream: true,
}),
});
```
### Using a local Ollama model with t1code
```bash
# Start Ollama with a code model
ollama run codellama
# Point t1code to local Ollama
export OPENAI_BASE_URL=http://localhost:11434/v1
export OPENAI_API_KEY=ollama
export OPENAI_MODEL=codellama
bunx @maria_rcks/t1code
```
### Using Together AI or other OpenAI-compatible providers
```bash
export OPENAI_API_KEY=$TOGETHER_API_KEY
export OPENAI_BASE_URL=https://api.together.xyz/v1
export OPENAI_MODEL=codellama/CodeLlama-34b-Instruct-hf
bunx @maria_rcks/t1code
```
---
## Common Patterns
### 1. One-off code generation session
```bash
OPENAI_API_KEY=your_key bunx @maria_rcks/t1code
```
### 2. Persistent global install with config in shell profile
```bash
# Add to ~/.bashrc or ~/.zshrc
export OPENAI_API_KEY=your_key
export OPENAI_MODEL=gpt-4o
# Then just run
t1code
```
### 3. Contributing a new TUI component (from source)
```typescript
// src/tui/MyPanel.ts - OpenTUI component pattern
import { Box, Text } from "opentui";
export function MyPanel({ content }: { content: string }) {
return (
<Box border="single" padding={1}>
<Text>{content}</Text>
</Box>
);
}
```
### 4. Adding a new keyboard shortcut (from source)
```typescript
// src/tui/keybindings.ts
import { onKey } from "opentui";
onKey("ctrl+r", () => {
// Reload/reset logic
resetChat();
});
```
---
## Troubleshooting
### `bunx` not found
Install Bun: https://bun.sh
```bash
curl -fsSL https://bun.sh/install | bash
```
### TUI renders incorrectly / garbled output
- Ensure your terminal supports 256-color ANSI (iTerm2, Warp, kitty, Windows Terminal, etc.)
- Try resizing your terminal window — some TUI layouts require minimum dimensions
- On Windows, use Windows Terminal or WSL2
### API errors / no response
- Verify `OPENAI_API_KEY` is set correctly
- Check that `OPENAI_BASE_URL` points to a valid OpenAI-compatible endpoint
- Test your API key independently:
```bash
curl https://api.openai.com/v1/models \
-H "Authorization: Bearer $OPENAI_API_KEY"
```
### `bun dev:tui` fails with module errors
```bash
# Clean install
rm -rf node_modules bun.lockb
bun install
bun dev:tui
```
### Slow streaming / no streaming output
- Confirm your provider supports SSE streaming on the `/chat/completions` endpoint
- Some self-hosted models (e.g., older Ollama builds) may need `stream: false` in the request body
---
## Links
- **npm:** https://www.npmjs.com/package/@maria_rcks/t1code
- **GitHub:** https://github.com/maria-rcks/t1code
- **OpenTUI:** https://github.com/nickvdyck/opentui
- **Original T3Code:** https://github.com/t3dotgg
- **License:** MIT
```
Related in Design
contribute
IncludedLocal-only OSS contribution command center. Auto-refreshes the user's in-flight PR and issue state on invoke so conversations start with full context — no need to brief Claude on what's in flight. Helps the user find issues to contribute to on GitHub, builds per-repo dossiers of what each upstream expects (CLA, DCO, branch convention, AI policy, draft-first, review bots, issue templates), runs deterministic gates before any external action so AI-assisted contributions don't reach maintainers as slop. State is markdown-only: candidate files at ~/.contribute-system/candidates/, repo dossiers at ~/.contribute-system/research/, append-only event log at ~/.contribute-system/log.jsonl. No database, no cloud calls. Use when the user asks about their PRs / issues / contributions, wants to find new work to take on, claim an issue, build/refresh a repo's dossier, or draft a Design Issue or PR. Trigger with "/contribute", "what's my PR status", "find a contribution", "claim issue X", "draft a Design Issue for Y", "refresh dossier for Z".
architectural-analysis
IncludedUser-triggered deep architectural analysis of a codebase or scoped subtree across eight modes — information architecture, data flow, integration points, UI surfaces, interaction patterns, data model, control flow, and failure modes. This skill should be used when the user asks to "diagram this codebase," "map the architecture," "show the data flow," "give me an ERD," "trace control flow," "find the integration points," "verify the layout pattern," "audit the UX architecture," or any similar request whose primary deliverable is mermaid diagrams plus cited reports under docs/architecture/. Dispatches haiku/sonnet sub-agents in parallel for per-mode exploration, then verifies every citation mechanically before any node lands in a diagram. Not for one-off prose explanations of code (use code-explanation) or for high-level system design from scratch (use system-design).
mcp
IncludedModel Context Protocol (MCP) server development and tool management. Languages: Python, TypeScript. Capabilities: build MCP servers, integrate external APIs, discover/execute MCP tools, manage multi-server configs, design agent-centric tools. Actions: create, build, integrate, discover, execute, configure MCP servers/tools. Keywords: MCP, Model Context Protocol, MCP server, MCP tool, stdio transport, SSE transport, tool discovery, resource provider, prompt template, external API integration, Gemini CLI MCP, Claude MCP, agent tools, tool execution, server config. Use when: building MCP servers, integrating external APIs as MCP tools, discovering available MCP tools, executing MCP capabilities, configuring multi-server setups, designing tools for AI agents.
react-native-skia
IncludedDesign, build, debug, and optimise high-polish animated graphics in React Native or Expo using @shopify/react-native-skia, Reanimated, and Gesture Handler. Use when the user wants canvas-driven UI, shaders, paths, rich text, image filters, sprite fields, Skottie, video frames, snapshots, web CanvasKit setup, or performance tuning for custom motion-heavy elements such as loaders, hero art, cards, charts, progress indicators, particle systems, or gesture-driven surfaces. Also use when the user asks for fluid, glow, glass, blob, parallax, 60fps/120fps, or GPU-friendly animated effects in React Native, even if they do not explicitly say "Skia". Do not use for ordinary form/layout work with standard views.
plaid
IncludedProduct Led AI Development — guides founders from idea to launched product. Six capabilities: Idea (discover a product idea), Validate (pressure-test the idea against fatal flaws, problem reality, competition, and 2-week MVP feasibility), Plan (vision intake + document generation), Design (translate image references into a design.md spec), Launch (go-to-market strategy), and Build (roadmap execution). Use when someone says "PLAID", "plaid idea", "help me find an idea", "product idea", "idea from my business", "idea from my expertise", "plaid validate", "validate my idea", "pressure-test", "is this idea good", "find fatal flaws", "validate the problem", "plan a product", "define my vision", "generate a PRD", "product strategy", "plaid design", "design from image", "translate image to design", "create design.md", "extract design tokens", "plaid launch", "go-to-market", "launch plan", "GTM strategy", "launch playbook", "plaid build", "build the app", "start building", or "execute the roadmap".
nextjs-framer-motion-animations
IncludedAdds production-safe Motion for React or Framer Motion animations to Next.js apps, including reveal, hover and tap micro-interactions, whileInView, stagger, AnimatePresence, layout and layoutId transitions, reorder, scroll-linked UI, and lightweight route-content transitions. Use when the user asks to add, refactor, or debug Motion or Framer Motion in App Router or Pages Router codebases, especially around server/client boundaries, reduced motion, LazyMotion, bundle size, hydration, or route transitions. Avoid for GSAP-style timelines, WebGL or 3D scenes, heavy scroll storytelling, or CSS-only effects unless Motion is explicitly requested.