53 lines
2.6 KiB
Plaintext
53 lines
2.6 KiB
Plaintext
# Ralph Progress Log
|
|
Started: Sun Feb 1 12:22:47 AM CET 2026
|
|
---
|
|
|
|
## Completed
|
|
|
|
### Task 1: Create language package with core types and helpers
|
|
- Created `internal/language/language.go` with Language struct, Auto constant
|
|
- Implemented FromCode, List, Codes, AllLanguageCodes, IsValidCode
|
|
- Full 57 language list from OpenAI Whisper
|
|
- All tests passing, typecheck passes
|
|
|
|
### Task 2: Add language list and provider-specific mappings
|
|
- Added `ToProviderFormat(code string, providerName string) string` function
|
|
- Handles auto-detect: whisper-cpp uses "auto", others use ""
|
|
- Deepgram locale mappings: en->en-US, pt->pt-BR, zh->zh-CN
|
|
- Added comprehensive test coverage for all provider formats
|
|
- All tests passing, typecheck passes
|
|
|
|
### Task 3: Create Model type with full metadata
|
|
- Created `internal/provider/model.go`
|
|
- ModelType enum: Transcription, LLM
|
|
- Model struct: ID, Name, Description, Type, Streaming, Local, AdapterType, SupportedLanguages, Endpoint, LocalInfo
|
|
- EndpointConfig: BaseURL, Path
|
|
- LocalModelInfo: Filename, Size, DownloadURL
|
|
- Helper methods: NeedsDownload(), IsStreaming(), SupportsLanguage(code), SupportsAllLanguages()
|
|
- SupportsLanguage("") always returns true (auto always allowed)
|
|
- All tests passing, typecheck passes
|
|
|
|
### Task 4: Refactor Provider interface to return Models
|
|
- Updated `internal/provider/provider.go` Provider interface
|
|
- Replaced old methods with: Models() []Model, DefaultModel(t ModelType) string, IsLocal() bool
|
|
- Added package-level helpers:
|
|
- GetModel(providerName, modelID string) (*Model, error)
|
|
- ModelsOfType(p Provider, t ModelType) []Model
|
|
- FindModelByID(modelID string) (*Model, Provider, error)
|
|
- ModelsForLanguage(p Provider, t ModelType, langCode string) []Model
|
|
- ValidateModelLanguage(providerName, modelID, langCode string) error
|
|
- Updated all providers (openai, groq, mistral, elevenlabs) with full Model metadata
|
|
- Updated TUI files to use ModelsOfType instead of old SupportsTranscription/SupportsLLM
|
|
- Added comprehensive tests for all new helper functions
|
|
- All tests passing, typecheck passes
|
|
|
|
### Task 5: Define BatchAdapter and StreamingAdapter interfaces
|
|
- Renamed `TranscriptionAdapter` to `BatchAdapter` in transcriber.go
|
|
- Updated all adapters (openai, groq, mistral, elevenlabs) to reference BatchAdapter in comments
|
|
- Updated SimpleTranscriber to use BatchAdapter
|
|
- Updated test mocks (MockTranscriptionAdapter -> MockBatchAdapter)
|
|
- Created `internal/transcriber/streaming.go` with:
|
|
- `TranscriptionResult` struct: Text, IsFinal, Error fields
|
|
- `StreamingAdapter` interface: Start, SendChunk, Results, Close methods
|
|
- All tests passing, typecheck passes
|