Skip to content

Commit

Permalink
Add new knowledge packs for JuliaLang, GenieFramework
Browse files Browse the repository at this point in the history
  • Loading branch information
svilupp committed Aug 19, 2024
1 parent 0e49097 commit da8c2c4
Show file tree
Hide file tree
Showing 6 changed files with 44 additions and 9 deletions.
29 changes: 23 additions & 6 deletions Artifacts.toml
Original file line number Diff line number Diff line change
@@ -1,18 +1,35 @@
["genie__textembedding3large-0-Float32"]
git-tree-sha1 = "453d1876a9c248dfc6a187e94ec4959199472162"
lazy = true

[["genie__textembedding3large-0-Float32".download]]
sha256 = "7c50469da95c7d6387b78307ea7ac15e981c61bd4121ec9772a39f9326ef8cfc"
url = "https://github.com/svilupp/AIHelpMeArtifacts/raw/main/artifacts/genie__v20240818__textembedding3large-3072-Float32__v1.0.tar.gz"

["genie__textembedding3large-1024-Bool"]
git-tree-sha1 = "723a7d2e694c183de2e5dc38e0cc54c8d9f57b4c"
lazy = true

[["genie__textembedding3large-1024-Bool".download]]
sha256 = "868fece03ec1f1a470f2f44e969b8452c3f7c83dcb6d03d7441d395cc753ab7a"
url = "https://github.com/svilupp/AIHelpMeArtifacts/raw/main/artifacts/genie__v20240818__textembedding3large-1024-Bool__v1.0.tar.gz"


["julia__textembedding3large-0-Float32"]
git-tree-sha1 = "a105a2482296fa0a80ce0c76677cc9ef673be70e"
git-tree-sha1 = "4d0b4f4627e768ab86d7b57f2968627462f5e490"
lazy = true

[["julia__textembedding3large-0-Float32".download]]
sha256 = "ff4e91908fb54b7919aad9d6a2ac5045124d43eb864fe9f96a7a68d304d4e0a2"
url = "https://github.com/svilupp/AIHelpMeArtifacts/raw/main/artifacts/julia__v1.10.2__textembedding3large-0-Float32__v1.0.tar.gz"
sha256 = "ff76b9b20b1307b5299977710f0d104f84cd4314cb30f5971ebe7d644742fc95"
url = "https://github.com/svilupp/AIHelpMeArtifacts/raw/main/artifacts/julialang__v20240819__textembedding3large-3072-Float32__v1.0.tar.gz"

["julia__textembedding3large-1024-Bool"]
git-tree-sha1 = "7eef82f15c72712b4f5fff2449ebf3ed64b56b14"
git-tree-sha1 = "365d9e59be009b7050db7112be0dd89b7be332bc"
lazy = true

[["julia__textembedding3large-1024-Bool".download]]
sha256 = "27186886d19ea4c3f1710b4bc70e8e809d906069d5de8c992c948d97d0f454da"
url = "https://github.com/svilupp/AIHelpMeArtifacts/raw/main/artifacts/julia__v1.10.2__textembedding3large-1024-Bool__v1.0.tar.gz"
sha256 = "8a88839594479ab12bd81a9a47e3bc4e2bd8aec02ad88db1dc3369b2cdb45e61"
url = "https://github.com/svilupp/AIHelpMeArtifacts/raw/main/artifacts/julialang__v20240819__textembedding3large-1024-Bool__v1.0.tar.gz"

["juliadata__textembedding3large-0-Float32"]
git-tree-sha1 = "5ea13051e16f01627a4c81fd74e664a396785934"
Expand Down
13 changes: 13 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,19 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Fixed

## [0.4.0]

### Added
- Added the knowledge pack for GenieFramework org. (alias `:genie`).

### Updated
- Updated the knowledge pack for core Julia docs (alias `:julia`).

Both were made possible by [Splendidbug](https://github.com/splendidbug)!

### Fixed
- Fixed a bug in `aihelp()` where `rerank=false` and `search=false` would not block these steps if they were previously enabled.

## [0.3.0]
### Added (thanks to [Splendidbug](https://github.com/splendidbug)!)
- New knowledge packs created by Splendidbug using `DocsScraper.jl` (to be registered soon, created as part of Google Summer of Code).
Expand Down
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "AIHelpMe"
uuid = "01402e1f-dc83-4213-a98b-42887d758baa"
authors = ["J S <[email protected]> and contributors"]
version = "0.3.0"
version = "0.4.0"

[deps]
HDF5 = "f67ccb44-e63f-5c2f-98bd-6dc0ccc4ba2f"
Expand Down
4 changes: 4 additions & 0 deletions src/generation.jl
Original file line number Diff line number Diff line change
Expand Up @@ -89,11 +89,15 @@ function aihelp(cfg_orig::RT.AbstractRAGConfig, index::RT.AbstractChunkIndex,
## Use Cohere reranking model
@assert !isempty(PT.COHERE_API_KEY) "COHERE_API_KEY is not set! Cannot use the reranker functionality."
cfg.retriever.reranker = RT.CohereReranker()
elseif !isnothing(rerank) && !rerank
cfg.retriever.reranker = RT.NoReranker()
end
if !isnothing(search) && search
##set TavilySearchRefiner - Requires TAVILY_API_KEY
@assert !isempty(PT.TAVILY_API_KEY) "TAVILY_API_KEY is not set! Cannot use the web search refinement functionality."
cfg.generator.refiner = RT.TavilySearchRefiner()
elseif !isnothing(search) && !search
cfg.generator.refiner = RT.NoRefiner()
end

## Run the RAG pipeline
Expand Down
2 changes: 1 addition & 1 deletion src/loading.jl
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ load_index!(:julia)
Or multiple packs
```julia
load_index!([:julia, :juliadata, :makie, :tidier, :plots, :sciml])
load_index!([:julia, :juliadata, :makie, :tidier, :plots, :sciml, :genie])
```
But we recommend loading ONLY the packs you expect to need - unnecessary packs introduce noise.
"""
Expand Down
3 changes: 2 additions & 1 deletion src/user_preferences.jl
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,15 @@ global MAIN_INDEX::Union{Nothing, RT.AbstractChunkIndex} = nothing
Currently available packs are:
- `:julia` - Julia documentation, standard library docstrings and a few extras (for Julia v1.10)
- `:juliadata` - JuliaData.jl organization documentation, eg, DataFrames.jl and similar packages
- `:genie` - GenieFramework organization documentation, eg, Genie.jl, Stipple.jl, StippleUI.jl, etc
- `:plots` - Plots.jl organization documentation, eg, Plots.jl, StatsPlots.jl, etc
- `:makie` - Makie.jl organization documentation
- `:tidier` - Tidier.jl organization documentation
- `:sciml` - SciML organization documentation
These packs have been sourced and packaged with DocsScraper.jl.
"""
const ALLOWED_PACKS = [:julia, :juliadata, :tidier, :sciml, :plots, :makie]
const ALLOWED_PACKS = [:julia, :juliadata, :tidier, :sciml, :plots, :makie, :genie]

"""
LOADED_PACKS
Expand Down

2 comments on commit da8c2c4

@svilupp
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator register

Release notes:

Added

  • Added the knowledge pack for GenieFramework org. (alias :genie).

Updated

  • Updated the knowledge pack for core Julia docs (alias :julia).

Both were made possible by Splendidbug!

Fixed

  • Fixed a bug in aihelp() where rerank=false and search=false would not block these steps if they were previously enabled.

Commits

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/113438

Tagging

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v0.4.0 -m "<description of version>" da8c2c46f0c6b5361328dd19ebf7af2264cc5060
git push origin v0.4.0

Please sign in to comment.