repository

package
v0.0.0-...-c829ac1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 4, 2025 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AppConfigRepo

type AppConfigRepo interface {
	GetAllNameValueInAppConfig(ctx context.Context, networkId string) (map[string]string, error)
}

func NewAppConfigRepository

func NewAppConfigRepository(db *gorm.DB) AppConfigRepo

type IAgentInfoKnowledgeBaseRepo

type IAgentInfoKnowledgeBaseRepo interface {
	Create(ctx context.Context, model *models.AgentInfoKnowledgeBase) (*models.AgentInfoKnowledgeBase, error)
	CreateList(ctx context.Context, models []*models.AgentInfoKnowledgeBase, agentInfoId uint) ([]*models.AgentInfoKnowledgeBase, error)
	ListByAgentIds(ctx context.Context, ids []uint) ([]*models.AgentInfoKnowledgeBase, error)
	GetByAgentId(ctx context.Context, id uint) (*models.AgentInfoKnowledgeBase, error)
}

func NewAgentInfoKnowledgeBaseRepository

func NewAgentInfoKnowledgeBaseRepository(db *gorm.DB) IAgentInfoKnowledgeBaseRepo

type IAgentInfoRepo

type IAgentInfoRepo interface {
	UpdateById(ctx context.Context, id uint, updatedFields map[string]interface{}) error
}

func NewAgentInfoRepository

func NewAgentInfoRepository(db *gorm.DB) IAgentInfoRepo

type KnowledgeBaseFileRepo

type KnowledgeBaseFileRepo interface {
	Create(ctx context.Context, model *models.KnowledgeBaseFile) (*models.KnowledgeBaseFile, error)
	UpdateByKnowledgeBaseId(ctx context.Context, kbId uint, updatedFields map[string]interface{}) error
	ListByKbId(ctx context.Context, kbId uint) ([]*models.KnowledgeBaseFile, error)
	DeleteByIds(ctx context.Context, ids []uint) error
	CalcTotalFee(ctx context.Context, kbId uint) (float64, error)
	UpdateTransferHash(ctx context.Context, kbFileIds []uint, transferHash string) error
}

func NewKnowledgeBaseFileRepository

func NewKnowledgeBaseFileRepository(db *gorm.DB) KnowledgeBaseFileRepo

type KnowledgeBaseRepo

type KnowledgeBaseRepo interface {
	GetById(ctx context.Context, id uint) (*models.KnowledgeBase, error)
	DeleteById(ctx context.Context, id uint) error
	Create(ctx context.Context, model *models.KnowledgeBase) (*models.KnowledgeBase, error)
	GetByStatus(ctx context.Context, status models.KnowledgeBaseStatus, offset, limit int) ([]*models.KnowledgeBase, error)
	List(ctx context.Context, req *models.ListKnowledgeBaseRequest) ([]*models.KnowledgeBase, error)
	UpdateStatus(ctx context.Context, model *models.KnowledgeBase) error
	UpdateById(ctx context.Context, id uint, updatedFields map[string]interface{}) error
	GetByKBId(context.Context, string) (*models.KnowledgeBase, error)
	GetByKBTokenId(context.Context, string) (*models.KnowledgeBase, error)
	GetManyByQuery(ctx context.Context, query string, orderOption string, offset int, limit int) ([]*models.KnowledgeBase, error)
	GetKBAgentsUsedOfSocialAgent(ctx context.Context, socialAgentId uint) ([]*models.KnowledgeBase, error)
}

func NewKnowledgeBaseRepository

func NewKnowledgeBaseRepository(db *gorm.DB) KnowledgeBaseRepo

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL