soverant / lattice

MIT License
0 stars 0 forks source link

Search Code via HTTP API #12

Open farhoud opened 1 month ago

farhoud commented 1 month ago

Title: Implement Endpoint to Search for Code

Description: Create an HTTP API endpoint to search for code using human language queries.

Acceptance Criteria:

Request Example:

GET /search?query=function+that+calculates+factorial

Response Example:

{
  "status": "success",
  "results": [
    {
      "file": "utils.py",
      "line": 10,
      "code": "def factorial(n):"
    },
    {
      "file": "math_helpers.py",
      "line": 5,
      "code": "def compute_factorial(number):"
    }
  ]
}

Tasks: