-
Notifications
You must be signed in to change notification settings - Fork 0
revert: remove llama-go local LLM integration #57
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
llama-go requires git submodules, make libbinding.a, and a go.work hack — it's not a self-contained Go module and breaks CI/CD. Removes: - LocalClient (local.go, local_stub.go) and all local tests - CosineSimilarity and similarity tests - EmbeddingComparer and Closer interfaces from client.go - Local* config fields and env overrides - "local" provider from config validation and CLI factory - build-local Makefile target - tcpipuk/llama-go dependency - Embedding comparison path in store_dedup.go Will be replaced by hybridgroup/yzma (purego, no CGo) in follow-up PRs. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Greptile OverviewGreptile SummaryThis PR reverts the previously-added llama-go based local LLM integration by removing the Within the codebase this primarily affects configuration validation/loading ( Confidence Score: 4/5
|
| Filename | Overview |
|---|---|
| Makefile | Removes the build-local target and llama-go build tag usage; remaining targets unchanged. |
| cmd/floop/main.go | Removes the "local" provider branch from createLLMClient and updates provider list comment. |
| go.mod | Drops tcpipuk/llama-go dependency from module requirements. |
| go.sum | Removes go.sum entries associated with the removed llama-go dependency. |
| internal/config/config.go | Removes local-model config fields/env overrides and disallows "local" provider; provider doc comment still mentions "local" (needs update). |
| internal/config/config_test.go | Updates config tests to remove local-provider cases and env override tests. |
| internal/dedup/dedup.go | Updates SimilarityMethod documentation to remove "embedding" as a valid value. |
| internal/dedup/store_dedup.go | Removes embedding-based similarity path; computeSimilarity now tries LLM CompareBehaviors then falls back to weighted Jaccard. |
| internal/llm/client.go | Removes optional EmbeddingComparer and Closer interfaces from the llm client package. |
| internal/llm/local.go | Deletes llamacpp-tagged LocalClient implementation (llama-go based). |
| internal/llm/local_integration_test.go | Deletes local LLM integration tests gated on llamacpp+integration build tags. |
| internal/llm/local_stub.go | Deletes non-llamacpp stub LocalClient implementation. |
| internal/llm/local_test.go | Deletes unit tests for the LocalClient and related interfaces. |
| internal/llm/similarity.go | Deletes CosineSimilarity helper previously used by embedding comparison. |
| internal/llm/similarity_test.go | Deletes tests for CosineSimilarity helper. |
Sequence Diagram
sequenceDiagram
participant User as CLI User
participant Config as internal/config
participant Main as cmd/floop
participant LLM as internal/llm
participant Dedup as internal/dedup/store_dedup
User->>Main: run floop
Main->>Config: Load() / LoadFromFile()
Config-->>Main: FloopConfig (LLM provider: anthropic/openai/ollama/subagent/"")
Main->>LLM: createLLMClient(cfg)
alt Provider == "subagent" or (Enabled && Provider == "")
Main->>LLM: DetectAndCreate()
LLM-->>Main: subagent client or nil
alt nil
Main->>LLM: NewFallbackClient()
end
else Provider == "openai" or "ollama"
Main->>LLM: NewOpenAIClient(ClientConfig)
else Provider == "anthropic"
Main->>LLM: NewAnthropicClient(ClientConfig)
else Provider empty/disabled
Main-->>LLM: nil client
end
User->>Dedup: DeduplicateStore / FindDuplicates
Dedup->>Dedup: computeSimilarity(a,b)
alt UseLLM && client != nil && client.Available()
Dedup->>LLM: CompareBehaviors(ctx,a,b)
alt success
LLM-->>Dedup: ComparisonResult(SemanticSimilarity)
else error
Dedup->>Dedup: weighted Jaccard fallback
end
else
Dedup->>Dedup: weighted Jaccard fallback
end
Dedup-->>User: DuplicateMatch list / report
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
15 files reviewed, 1 comment
Additional Comments (1)
|
Summary
tcpipuk/llama-gomake libbinding.a, and ago.workhack — not a self-contained Go module, breaks CI/CDWhy revert instead of modify?
The replacement (hybridgroup/yzma, purego) has a fundamentally different architecture — no build tags, no CGo, no stub file. Cleaner to revert and re-add as stacked PRs:
Test plan
go build ./cmd/floop— builds cleanlygo vet ./...— no issuesgo test ./...— all 25 packages pass🤖 Generated with Claude Code