feat: add AI integration (#27)

* wip: add AI integration|

* wip: add job selection with popover

* wip: add AI integration

* wip: add in openai support

* wip: add in query params and work on ui

* wip: finalize UI

* chore: cleanup and docs
This commit is contained in:
Jayden Pyles
2024-07-31 20:08:56 -05:00
committed by GitHub
parent 99480f3481
commit 55181ec349
31 changed files with 2864 additions and 2121 deletions

View File

@@ -6,6 +6,10 @@ from datetime import datetime
import pydantic
class FetchOptions(pydantic.BaseModel):
chat: Optional[bool] = None
class Element(pydantic.BaseModel):
name: str
xpath: str
@@ -32,6 +36,7 @@ class SubmitScrapeJob(pydantic.BaseModel):
result: Optional[dict[str, Any]] = None
job_options: JobOptions
status: str = "Queued"
chat: Optional[str] = None
class RetrieveScrapeJobs(pydantic.BaseModel):
@@ -54,3 +59,7 @@ class UpdateJobs(pydantic.BaseModel):
ids: list[str]
field: str
value: Any
class AI(pydantic.BaseModel):
messages: list[Any]