Skip to content

Commit

Permalink
fix: names
Browse files Browse the repository at this point in the history
  • Loading branch information
henomis committed May 14, 2024
1 parent ed42e47 commit 60f4ad8
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions rag/rag.go
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ func (r *RAG) WithLoader(sourceRegexp *regexp.Regexp, loader Loader) *RAG {
func (r *RAG) AddSources(ctx context.Context, sources ...string) error {
ctx, span, err := r.startObserveSpan(
ctx,
"RAG AddSources",
"rag-add-source",
types.M{
"chunkSize": r.chunkSize,
"chunkOverlap": r.chunkOverlap,
Expand Down Expand Up @@ -118,7 +118,7 @@ func (r *RAG) AddSources(ctx context.Context, sources ...string) error {
func (r *RAG) AddDocuments(ctx context.Context, documents ...document.Document) error {
ctx, span, err := r.startObserveSpan(
ctx,
"RAG AddDocument",
"rag-add-document",
types.M{
"chunkSize": r.chunkSize,
"chunkOverlap": r.chunkOverlap,
Expand All @@ -144,7 +144,7 @@ func (r *RAG) AddDocuments(ctx context.Context, documents ...document.Document)
func (r *RAG) Retrieve(ctx context.Context, query string) ([]string, error) {
ctx, span, err := r.startObserveSpan(
ctx,
"RAG Retrieve",
"rag-retrieve",
types.M{
"query": query,
"topK": r.topK,
Expand Down
2 changes: 1 addition & 1 deletion rag/rag_fusion.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ func NewFusion(index *index.Index, llm LLM) *Fusion {
func (r *Fusion) Retrieve(ctx context.Context, query string) ([]string, error) {
ctx, span, err := r.startObserveSpan(
ctx,
"RAGFusion Retrieve",
"rag-fusion-retrieve",
types.M{
"query": query,
"topK": r.topK,
Expand Down
2 changes: 1 addition & 1 deletion rag/sub_document.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ func (r *SubDocumentRAG) WithLoader(sourceRegexp *regexp.Regexp, loader Loader)
func (r *SubDocumentRAG) AddSources(ctx context.Context, sources ...string) error {
ctx, span, err := r.startObserveSpan(
ctx,
"SubDocumentRAG AddSources",
"rag-subdocument-add-sources",
types.M{
"chunkSize": r.chunkSize,
"childChunkSize": r.childChunkSize,
Expand Down

0 comments on commit 60f4ad8

Please sign in to comment.