-
Notifications
You must be signed in to change notification settings - Fork 107
automated readthedocs #177
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
36 commits
Select commit
Hold shift + click to select a range
bddb97d
adding readthedocs stuff
TLSDC 0e58b1b
adding .readthedocs.yml
TLSDC 1f581fd
rename
TLSDC 57849b5
update
TLSDC dcd9e15
updates
TLSDC 2134ed5
updates
TLSDC 793979d
updates
TLSDC dcd6ba8
please
TLSDC 0b2ba57
please
TLSDC d6a44e3
i have trust
TLSDC 6c4524d
ReadTheDoc base template
TLSDC dee0478
fixing unused dep
TLSDC f050a0d
fancier theme options
TLSDC d503c1a
adding some documentation
TLSDC 2567559
adding some init files
TLSDC b27ac9e
adding workflow
TLSDC 8ddc050
Merge branch 'main' into tlsdc/docs
TLSDC 9f130eb
version bump
TLSDC 3cec216
fixing rtd
TLSDC ef94260
automating version numner
TLSDC 9f0018a
version bump
TLSDC 4c7d60b
fixing rtd git workflow
TLSDC b9a12fb
cleaning up
TLSDC 6e9fd99
quick test
TLSDC dd2198a
version
TLSDC 4403ee0
testing some more stuff
TLSDC 2373fda
one last test
TLSDC ced0416
triggers only on non dev tags
TLSDC 4531a5e
changing workflows
TLSDC 83a84c8
version bump
TLSDC b05cc70
fixing workflow
TLSDC 00a37f0
version bump
TLSDC 8842da5
tmp updates just for a check
TLSDC b4d6c89
last one
TLSDC 521fbbc
lgtm
TLSDC 88326f2
Explicit tag push
gasse File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,48 @@ | ||
| name: Update Docs with Versioning | ||
|
|
||
| on: | ||
| push: | ||
| tags: | ||
| - 'v[0-9]+.[0-9]+.[0-9]+' | ||
| workflow_dispatch: | ||
|
|
||
| permissions: | ||
| contents: write | ||
|
|
||
| jobs: | ||
| build-docs: | ||
| runs-on: ubuntu-latest | ||
|
|
||
| steps: | ||
| - name: Checkout Repository | ||
| uses: actions/checkout@v3 | ||
| with: | ||
| fetch-depth: 0 | ||
|
|
||
| - name: Set up Python | ||
| uses: actions/setup-python@v4 | ||
| with: | ||
| python-version: 3.x | ||
|
|
||
| - name: Install Dependencies | ||
| run: | | ||
| python -m pip install --upgrade pip | ||
| pip install sphinx | ||
|
|
||
| - name: Run Sphinx-apidoc | ||
| run: | | ||
| cd docs | ||
| sphinx-apidoc ../src -o ./source | ||
|
|
||
| - name: Commit and Push to Generated Docs Branch | ||
| env: | ||
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
| run: | | ||
| git config --global user.name "github-actions[bot]" | ||
| git config --global user.email "github-actions[bot]@users.noreply.github.com" | ||
| git checkout -b generated-docs | ||
| git add . | ||
| git commit -m "Update docs for version $GITHUB_REF_NAME [skip ci]" || echo "No changes to commit" | ||
| git push origin generated-docs --force | ||
| git tag docs/$GITHUB_REF_NAME | ||
| git push origin tag docs/$GITHUB_REF_NAME |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,35 @@ | ||
| # Read the Docs configuration file for Sphinx projects | ||
| # See https://docs.readthedocs.io/en/stable/config-file/v2.html for details | ||
|
|
||
| # Required | ||
| version: 2 | ||
|
|
||
| # Set the OS, Python version and other tools you might need | ||
| build: | ||
| os: ubuntu-22.04 | ||
| tools: | ||
| python: "3.12" | ||
| # You can also specify other tool versions: | ||
| # nodejs: "20" | ||
| # rust: "1.70" | ||
| # golang: "1.20" | ||
|
|
||
| # Build documentation in the "docs/" directory with Sphinx | ||
| sphinx: | ||
| configuration: docs/source/conf.py | ||
| # You can configure Sphinx to use a different builder, for instance use the dirhtml builder for simpler URLs | ||
| # builder: "dirhtml" | ||
| # Fail on all warnings to avoid broken references | ||
| # fail_on_warning: true | ||
|
|
||
| # Optionally build your docs in additional formats such as PDF and ePub | ||
| # formats: | ||
| # - epub | ||
|
|
||
| # Optional but recommended, declare the Python requirements required | ||
| # to build your documentation | ||
| # See https://docs.readthedocs.io/en/stable/guides/reproducible-builds.html | ||
| python: | ||
| install: | ||
| - requirements: docs/source/requirements.txt |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| # Minimal makefile for Sphinx documentation | ||
| # | ||
|
|
||
| # You can set these variables from the command line, and also | ||
| # from the environment for the first two. | ||
| SPHINXOPTS ?= | ||
| SPHINXBUILD ?= sphinx-build | ||
| SOURCEDIR = source | ||
| BUILDDIR = build | ||
|
|
||
| # Put it first so that "make" without argument is like "make help". | ||
| help: | ||
| @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) | ||
|
|
||
| .PHONY: help Makefile | ||
|
|
||
| # Catch-all target: route all unknown targets to Sphinx using the new | ||
| # "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). | ||
| %: Makefile | ||
| @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,35 @@ | ||
| @ECHO OFF | ||
|
|
||
| pushd %~dp0 | ||
|
|
||
| REM Command file for Sphinx documentation | ||
|
|
||
| if "%SPHINXBUILD%" == "" ( | ||
| set SPHINXBUILD=sphinx-build | ||
| ) | ||
| set SOURCEDIR=source | ||
| set BUILDDIR=build | ||
|
|
||
| %SPHINXBUILD% >NUL 2>NUL | ||
| if errorlevel 9009 ( | ||
| echo. | ||
| echo.The 'sphinx-build' command was not found. Make sure you have Sphinx | ||
| echo.installed, then set the SPHINXBUILD environment variable to point | ||
| echo.to the full path of the 'sphinx-build' executable. Alternatively you | ||
| echo.may add the Sphinx directory to PATH. | ||
| echo. | ||
| echo.If you don't have Sphinx installed, grab it from | ||
| echo.https://www.sphinx-doc.org/ | ||
| exit /b 1 | ||
| ) | ||
|
|
||
| if "%1" == "" goto help | ||
|
|
||
| %SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O% | ||
| goto end | ||
|
|
||
| :help | ||
| %SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O% | ||
|
|
||
| :end | ||
| popd |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| # Minimal makefile for Sphinx documentation | ||
| # | ||
|
|
||
| # You can set these variables from the command line, and also | ||
| # from the environment for the first two. | ||
| SPHINXOPTS ?= | ||
| SPHINXBUILD ?= sphinx-build | ||
| SOURCEDIR = . | ||
| BUILDDIR = _build | ||
|
|
||
| # Put it first so that "make" without argument is like "make help". | ||
| help: | ||
| @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) | ||
|
|
||
| .PHONY: help Makefile | ||
|
|
||
| # Catch-all target: route all unknown targets to Sphinx using the new | ||
| # "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). | ||
| %: Makefile | ||
| @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,75 @@ | ||
| # Configuration file for the Sphinx documentation builder. | ||
| # | ||
| # For the full list of built-in configuration values, see the documentation: | ||
| # https://www.sphinx-doc.org/en/master/usage/configuration.html | ||
|
|
||
| # -- Project information ----------------------------------------------------- | ||
| # https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information | ||
|
|
||
| import os | ||
| import subprocess | ||
|
|
||
|
|
||
| # Automatically retrieve the project version from Git | ||
| def get_version(): | ||
| try: | ||
| return subprocess.check_output(["git", "describe", "--tags"], encoding="utf-8").strip() | ||
| except Exception: | ||
| return "0.0.0" | ||
|
|
||
|
|
||
| project = "AgentLab" | ||
| author = "ServiceNow" | ||
| release = get_version() # Full version string including tags | ||
| version = release # Short version (e.g., 1.0) | ||
|
|
||
|
|
||
| # -- General configuration --------------------------------------------------- | ||
| # https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration | ||
| extensions = [ | ||
| "sphinx.ext.duration", | ||
| "sphinx.ext.doctest", | ||
| "sphinx.ext.autodoc", | ||
| "sphinx.ext.autosummary", | ||
| "sphinx.ext.intersphinx", | ||
| # "myst_parser", # Add this to enable Markdown parsing | ||
| "sphinx.ext.napoleon", | ||
| ] | ||
|
|
||
| intersphinx_mapping = { | ||
| "rtd": ("https://docs.readthedocs.io/en/stable/", None), | ||
| "python": ("https://docs.python.org/3/", None), | ||
| "sphinx": ("https://www.sphinx-doc.org/en/master/", None), | ||
| } | ||
| intersphinx_disabled_domains = ["std"] | ||
|
|
||
| autodoc_default_options = { | ||
| "members": True, | ||
| "undoc-members": True, | ||
| "show-inheritance": True, | ||
| } | ||
|
|
||
| source_suffix = { | ||
| ".rst": "restructuredtext", | ||
| } | ||
|
|
||
|
|
||
| templates_path = ["_templates"] | ||
| exclude_patterns = [] | ||
|
|
||
|
|
||
| # -- Options for HTML output ------------------------------------------------- | ||
| # https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output | ||
|
|
||
| html_theme = "sphinx_rtd_theme" | ||
| html_theme_options = { | ||
| "navigation_depth": -1, | ||
| "collapse_navigation": False, | ||
| "display_version": True, | ||
| "version_selector": True, | ||
| } | ||
| html_static_path = ["_static"] | ||
|
|
||
| import sys | ||
|
|
||
| sys.path.insert(0, os.path.abspath("../../src")) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| .. AgentLab documentation master file, created by | ||
| sphinx-quickstart on Tue Nov 26 11:21:39 2024. | ||
| You can adapt this file completely to your liking, but it should at least | ||
| contain the root `toctree` directive. | ||
|
|
||
| AgentLab documentation | ||
| ====================== | ||
|
|
||
| ReadTheDoc Page for AgentLab: https://agentlab.readthedocs.io/en/latest/ | ||
|
|
||
|
|
||
| .. autosummary:: | ||
| :toctree: | ||
| :recursive: | ||
|
|
||
| agentlab.agents | ||
| agentlab.analyze | ||
| agentlab.llm | ||
| agentlab.experiments | ||
| agentlab.ui_assistant |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,35 @@ | ||
| @ECHO OFF | ||
|
|
||
| pushd %~dp0 | ||
|
|
||
| REM Command file for Sphinx documentation | ||
|
|
||
| if "%SPHINXBUILD%" == "" ( | ||
| set SPHINXBUILD=sphinx-build | ||
| ) | ||
| set SOURCEDIR=. | ||
| set BUILDDIR=_build | ||
|
|
||
| %SPHINXBUILD% >NUL 2>NUL | ||
| if errorlevel 9009 ( | ||
| echo. | ||
| echo.The 'sphinx-build' command was not found. Make sure you have Sphinx | ||
| echo.installed, then set the SPHINXBUILD environment variable to point | ||
| echo.to the full path of the 'sphinx-build' executable. Alternatively you | ||
| echo.may add the Sphinx directory to PATH. | ||
| echo. | ||
| echo.If you don't have Sphinx installed, grab it from | ||
| echo.https://www.sphinx-doc.org/ | ||
| exit /b 1 | ||
| ) | ||
|
|
||
| if "%1" == "" goto help | ||
|
|
||
| %SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O% | ||
| goto end | ||
|
|
||
| :help | ||
| %SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O% | ||
|
|
||
| :end | ||
| popd |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,2 @@ | ||
| agentlab | ||
| sphinx-rtd-theme |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1 +1 @@ | ||
| __version__ = "0.3.2.dev1" | ||
| __version__ = "v0.3.2" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| """ | ||
| AgentLab's pre-implemented agents. | ||
|
|
||
| This module contains the agent implementations for AgentLab. With currently: | ||
|
|
||
| - GenericAgent: Our baseline agent for evaluation | ||
|
|
||
| - MostBasicAgent: A basic agent for learning our framework | ||
|
|
||
| - TapeAgent: An agent that uses the Tape data structure to perform actions | ||
|
|
||
| - VisualWebArenaAgent: An implentation of the agent used in WebArena and VisualWebArena | ||
| """ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.