{"id":25428845,"url":"https://github.com/luillyfe/travel-agent","last_synced_at":"2025-05-14T08:35:23.856Z","repository":{"id":277912863,"uuid":"933731911","full_name":"luillyfe/travel-agent","owner":"luillyfe","description":null,"archived":false,"fork":false,"pushed_at":"2025-03-25T15:24:50.000Z","size":68,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-25T16:30:59.620Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/luillyfe.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-02-16T15:13:32.000Z","updated_at":"2025-02-25T09:01:13.000Z","dependencies_parsed_at":"2025-03-25T16:37:49.480Z","dependency_job_id":null,"html_url":"https://github.com/luillyfe/travel-agent","commit_stats":null,"previous_names":["luillyfe/travel-agent"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/luillyfe%2Ftravel-agent","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/luillyfe%2Ftravel-agent/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/luillyfe%2Ftravel-agent/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/luillyfe%2Ftravel-agent/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/luillyfe","download_url":"https://codeload.github.com/luillyfe/travel-agent/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254104747,"owners_count":22015536,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-02-17T01:48:36.164Z","updated_at":"2025-05-14T08:35:23.849Z","avatar_url":"https://github.com/luillyfe.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# AI Travel Agent API\n\nA RESTful API service that processes travel booking requests using AI to find optimal flight options based on natural language queries.\n\n## Project Structure\n\n```\n.\n├── cmd/\n│   └── app/\n│       └── main.go           # Application entry point\n├── internal/\n│   ├── config/              # Configuration handling\n│   │   └── config.go\n│   ├── handlers/            # HTTP request handlers\n│   │   └── booking.go\n│   ├── models/              # Data models\n│   │   └── booking.go\n│   ├── server/             # Server implementation\n│   │   └── server.go\n│   └── service/            # Business logic\n│       ├── ai/             # AI inference services\n│       │   ├── inference.go\n│       │   ├── travelParameterExtraction.go\n│       │   └── flightRecommendation.go\n│       └── booking.go\n├── pkg/\n│   └── utils/              # Shared utilities\n│       └── utils.go\n├── tests/                  # Test suites\n│   ├── booking_test.go\n│   ├── inference_test.go\n│   └── server_test.go\n└── api/\n    └── openapi.yaml        # API specifications\n```\n\n## Core Components\n\n### Models\n\n- `BookingRequest`: Represents the initial booking request with query and deadline\n- `BookingResponse`: Contains booking status and flight details\n- `Flight`: Detailed flight information\n\n### Services\n\n- `BookingService`: Core business logic for processing booking requests\n- `InferenceEngine`: Handles AI parameter extraction from natural language\n- `TravelParameterExtraction`: Processes travel-specific parameters\n- `FlightRecommendation`: AI-powered flight recommendations based on user preferences\n\n### Configuration\n\n- Environment-based configuration with JSON file support\n- API keys and server settings management\n- Default configurations with override capability\n\n## API Endpoints\n\n### Create Booking\n\n```\nPOST /api/v1/bookings\n```\n\nRequest body:\n\n```json\n{\n  \"query\": \"Book a flight from Cúcuta to Paris on March 10th for a 3-day trip\",\n  \"deadline\": \"2025-03-18T15:04:05Z\"\n}\n```\n\nResponse:\n\n```json\n{\n  \"id\": \"123e4567-e89b-12d3-a456-426614174000\",\n  \"status\": \"processing\",\n  \"query\": \"Book a flight from Cúcuta to Paris on March 10th for a 3-day trip\",\n  \"deadline\": \"2025-03-18T15:04:05Z\",\n  \"flight\": {\n    \"airline\": \"\",\n    \"flight_number\": \"\",\n    \"departure_city\": \"Cúcuta\",\n    \"arrival_city\": \"Paris\",\n    \"departure_time\": \"2025-03-01T10:00:00Z\",\n    \"arrival_time\": \"2025-03-01T22:00:00Z\",\n    \"price\": 0,\n    \"currency\": \"\"\n  },\n  \"created_at\": \"2025-02-16T15:04:05Z\",\n  \"updated_at\": \"2025-02-16T15:04:05Z\",\n  \"message\": \"Processing your request\"\n}\n```\n\n### Get Booking Status\n\n```\nGET /api/v1/bookings/status?id={booking_id}\n```\n\n## Getting Started\n\n1. Clone the repository\n2. Set up configuration:\n   ```bash\n   # Set environment variable for AI provider\n   export AI_PROVIDER_API_KEY=your_api_key\n   ```\n3. Install dependencies:\n   ```bash\n   go mod tidy\n   ```\n4. Run the server:\n   ```bash\n   go run cmd/app/main.go\n   ```\n\n## Testing\n\nRun the test suite:\n\n```bash\ngo test ./...\n```\n\n## Implementation Status\n\nCompleted:\n\n- ✅ Basic API structure and routing\n- ✅ Request/Response models\n- ✅ Configuration management\n- ✅ AI integration framework\n- ✅ Parameter extraction from natural language\n- ✅ Flight recommendation engine\n- ✅ Preference-based scoring system\n\nIn Progress:\n\n- 🔄 Booking service implementation\n- 🔄 Test suite foundation\n- 🔄 Flight search integration\n\nPending:\n\n- ⏳ Database persistence\n- ⏳ Complete booking status retrieval\n- ⏳ Authentication/Authorization\n- ⏳ Advanced error handling middleware\n- ⏳ Metrics and monitoring\n- ⏳ Rate limiting\n- ⏳ Caching layer\n\n## Contributing\n\n1. Fork the repository\n2. Create a feature branch following the format:\n   - `feature/description` for new features\n   - `fix/description` for bug fixes\n   - `docs/description` for documentation changes\n3. Commit your changes using conventional commits\n4. Push to the branch\n5. Create a Pull Request against the `develop` branch\n\nNote: The `main` branch is protected. All changes must go through PR review.\n\n## License\n\nThis project is licensed under the MIT License - see the LICENSE file for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fluillyfe%2Ftravel-agent","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fluillyfe%2Ftravel-agent","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fluillyfe%2Ftravel-agent/lists"}