| name | speak-local-dev-loop |
| description | Configure Speak local development with mocked tutors and audio testing.
Use when setting up a development environment, configuring test workflows,
or building language learning features locally.
Trigger with phrases like "speak dev setup", "speak local development",
"speak dev environment", "develop with speak".
|
| allowed-tools | Read, Write, Edit, Bash(npm:*), Bash(pnpm:*), Grep |
| version | 1.14.0 |
| license | MIT |
| author | Jeremy Longshore <jeremy@intentsolutions.io> |
| tags | ["saas","speak","testing","workflow"] |
| compatibility | Designed for Claude Code, also compatible with Codex and OpenClaw |
Speak Local Dev Loop
Overview
Set up a fast local development workflow for Speak language learning integrations. Includes mock tutor responses for offline development, audio test fixtures, and a debug mode for scoring analysis.
Prerequisites
- Completed
speak-install-auth setup
- Node.js 18+ with npm/pnpm
- ffmpeg installed (for audio conversion)
Instructions
Step 1: Project Structure
speak-app/
src/
speak/client.ts # Speak API client
speak/tutor.ts # AI tutor conversation manager
speak/pronunciation.ts # Pronunciation assessment
speak/audio.ts # Audio recording and preprocessing
tests/
mocks/ # Mock responses for offline dev
fixtures/ # Sample audio files for testing
unit/ # Unit tests with mocked API
integration/ # Integration tests (needs API key)
.env.development # Dev credentials
.env.test # Test credentials (mock mode)
Step 2: Mock Tutor for Offline Development
export class MockSpeakClient {
async startConversation(config: any) {
return {
id: 'mock-session-123',
firstPrompt: {
text: 'Hola! Bienvenido. Como te llamas?',
audioUrl: null,
},
};
}
async sendTurn(sessionId: string, input: any) {
return {
tutorText: 'Muy bien! Tu pronunciacion es buena.',
pronunciationScore: 85,
corrections: [],
: [],
};
}
() {
{
: ,
: [
{ : , : , : [] },
{ : , : , : [
{ : , : , : }
]},
],
};
}
}