Documentation ¶
Index ¶
- type Config
- type Server
- func (s *Server) CreateDS(c *gin.Context)
- func (s *Server) DeleteDS(c *gin.Context)
- func (s *Server) GetDS(c *gin.Context)
- func (s *Server) IngestIntoDS(c *gin.Context)
- func (s *Server) ListDS(c *gin.Context)
- func (s *Server) RemoveDocFromDS(c *gin.Context)
- func (s *Server) RemoveFileFromDS(c *gin.Context)
- func (s *Server) RetrieveFromDS(c *gin.Context)
- func (s *Server) Start(ctx context.Context, cfg Config) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Server ¶
func (*Server) CreateDS ¶
CreateDS creates a new dataset. @Summary Create a new dataset @Description Create a new dataset @Tags datasets @Accept json @Produce json @Param dataset body types.Dataset true "Dataset object" @Router /datasets/create [post] @Success 200 {object} types.Dataset
func (*Server) DeleteDS ¶
DeleteDS deletes a dataset by ID. @Summary Delete a dataset @Description Delete a dataset by ID @Tags datasets @Produce json @Param id path string true "Dataset ID" @Router /datasets/{id} [delete] @Success 200 {object} gin.H
func (*Server) GetDS ¶
GetDS gets a dataset by ID. @Summary Get a dataset @Description Get a dataset by ID @Tags datasets @Produce json @Param id path string true "Dataset ID" @Router /datasets/{id} [get] @Success 200 {object} types.Dataset
func (*Server) IngestIntoDS ¶
IngestIntoDS ingests content into a dataset by ID. @Summary Ingest content into a dataset @Description Ingest content into a dataset by ID @Tags datasets @Accept json @Produce json @Param id path string true "Dataset ID" @Router /datasets/{id}/ingest [post] @Success 200 {object} types.IngestResponse
func (*Server) ListDS ¶
ListDS lists all datasets. @Summary List all datasets @Description List all datasets @Tags datasets @Produce json @Router /datasets [get] @Success 200 {object} []types.Dataset
func (*Server) RemoveDocFromDS ¶
RemoveDocFromDS removes a document from a dataset by ID. If the owning file context is now empty, the FileIndex is removed. @Summary Remove a document from a dataset @Description Remove a document from a dataset by ID @Tags datasets @Accept json @Produce json @Param id path string true "Dataset ID" @Param doc_id path string true "Document ID" @Router /datasets/{id}/documents/{doc_id} [delete] @Success 200 {object} gin.H
func (*Server) RemoveFileFromDS ¶
RemoveFileFromDS removes a file from a dataset by ID. @Summary Remove a file from a dataset @Description Remove a file from a dataset by ID @Tags datasets @Accept json @Produce json @Param id path string true "Dataset ID" @Param file_id path string true "File ID" @Router /datasets/{id}/files/{file_id} [delete] @Success 200 {object} gin.H
func (*Server) RetrieveFromDS ¶
RetrieveFromDS retrieves content from a dataset by ID. @Summary Retrieve content from a dataset @Description Retrieve content from a dataset by ID @Tags datasets @Accept json @Produce json @Param id path string true "Dataset ID" @Router /datasets/{id}/retrieve [post] @Success 200 {object} []vectorstore.Document