feat: build Go-based SearXNG-compatible search service
Implement an API-first Go rewrite with local engine adapters, upstream fallback, and Nix-based tooling so searches can run without matching the original UI while preserving response compatibility. Made-with: Cursor
This commit is contained in:
parent
7783367c71
commit
dc44837219
32 changed files with 3330 additions and 0 deletions
17
internal/engines/engine.go
Normal file
17
internal/engines/engine.go
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
package engines
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/ashie/gosearch/internal/contracts"
|
||||
)
|
||||
|
||||
// Engine is a Go-native implementation of a SearXNG engine.
|
||||
//
|
||||
// Implementations should return a SearchResponse containing only the results
|
||||
// for that engine subset; the caller will merge multiple engine responses.
|
||||
type Engine interface {
|
||||
Name() string
|
||||
Search(ctx context.Context, req contracts.SearchRequest) (contracts.SearchResponse, error)
|
||||
}
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue