Skip to content

Commit 32e3d79

Browse files
htahir1strickvlznegringithub-actions[bot]actions-user
committed
Restructure entire docs (#3447)
* Add legacy docs section to table of contents * Add redirects and new table of contents for component guide * Add user guide for ZenML with starter and production guides. (50 chars) * Update link to artifact store in cache documentation * GITBOOK-1: No subject * Revert "GITBOOK-1: No subject" This reverts commit 81ba95a. * Update caching behavior to include artifact store link.<commit message> * Update caching behavior and artifact store link * Update artifact store link in cache-previous-executions.md * Update caching behavior in ZenML user guide * Update artifact store link in cache documentation * Update cache-previous-executions.md with corrected link * GITBOOK-2: No subject * GITBOOK-1: No subject * Remove SDK & CLI reference link from TOC * GITBOOK-1: No subject * GITBOOK-2: No subject * Add link checker script for markdown files * Update links in markdown files to absolute URLs * Fixes for docs links (#3425) * format script * Enhance link replacement functionality by adding optional substring filter in replace_links_in_file. This allows users to specify a substring to limit which links are replaced, improving control over the link transformation process. * Fixed links to how-to pages from stacks guides * Fix links to reference pages from stacks guides * Update GCP CLI configuration link in container registries documentation * Enhance link checking functionality in check_links_with_substring to differentiate between internal documentation paths and other links. Update docstring for clarity and improve link replacement logic in replace_links_in_file by removing the substring parameter, ensuring only relevant links are processed. This improves the accuracy of link validation and replacement in markdown files. * Fix buggy link checker * Fix links to getting-started pages from stacks guides * Document the link_checker script * Fix links to starter-guide pages from stack guides * add url mapping + documentation * Fix links to production-guide pages from stack guides * Fix links to tutorials from getting-started section * Fix links to tutorials from how-to section * Fix links to tutorials from referenc section * Update default source directories in format.sh to include link_checker.py * Refine link filtering logic in link_checker.py to ensure only relevant internal documentation paths are included. Update comments for clarity. * Fix links to stacks guides from getting-started section * Fix links to stacks guides from how-to section * Fix links to stacks guides from reference section * Fix links to stacks guides from 'framework' meta-section * Enhance link replacement logic in link_checker.py to store line-specific replacements and apply them in a single pass. This change improves the accuracy of link transformations while maintaining the original line structure during modifications. * Fix multi-links * Fix links to framework section from tutorials * Fix links to stacks guides from tutorials * Fix broken links * Fix duplicated path in URL * Added API docs * Added API docs * Add Pro API section to Table of Contents * Update API endpoints in OSS API documentation * GITBOOK-5: No subject * Add redirects for project setup and management paths * Update SDK Docs URLs to include ".html" extension.- Update SDK Docs URLs to include ".html" extension * Add ZenML Pro API documentation and authentication instructions * Update Pro API documentation link in API reference * Update ZenML Client documentation links * Fix more links (#3436) * Enhance link validity checks in link_checker.py - Added an additional check for Gitbook URLs to identify pages that return a 200 status code but contain a "noindex" meta tag, indicating a non-existent page. - Updated the transform_relative_link function to skip links to assets and Gitbook resources. - Modified the replace_links_in_file function to also skip links to assets and Gitbook resources, ensuring cleaner link processing. * Fix internal links inside component-guide * Fix internal links inside getting-started section * Refactor link replacement logic in link_checker.py - Introduced a mechanism to track valid replacements, ensuring only valid links are applied during the replacement process. - Enhanced the handling of inline and reference-style links by collecting potential replacements before applying them. - Updated the logic to apply replacements conditionally based on validation results, improving the accuracy of link processing. - Removed unnecessary dry run checks and streamlined the writing of modified content back to the file. * Fix internal links in how-to section * Fixing edge case links inside how-to section --------- Co-authored-by: Hamza Tahir <[email protected]> * Add redirects to ZenML Pro and project setup pages * Add link checking workflow and script (and fix some broken links) (#3438) * Add link checking workflow and script - Introduced a GitHub Actions workflow (`check-links.yml`) to automate the checking of absolute and relative links in markdown files upon push and pull request events. - Added a new script (`check_relative_links.py`) to verify that relative links in markdown files point to existing files in the repository, enhancing documentation integrity. - The script scans markdown files, extracts relative links, and checks their validity without making HTTP requests, providing detailed output for any broken links found. This addition aims to improve the reliability of documentation links and streamline the review process for changes in markdown files. * Fixing static pro links * Fix more pro links * Update internal links in Kubernetes orchestrator documentation - Changed links for the remote artifact store and remote container registry sections to point to the correct README files, ensuring accurate navigation within the documentation. This update aims to enhance the clarity and usability of the Kubernetes orchestrator guide. * Update documentation for CloudpickleMaterializer warning - Clarified the warning regarding the use of the built-in CloudpickleMaterializer, emphasising the potential security risks associated with uploading arbitrary objects. - Improved the link to the custom Materializer documentation for better guidance on creating robust and efficient formats. This update aims to enhance user awareness of security implications and provide clearer instructions for safer practices in ZenML step output handling. * Update internal links in API documentation - Modified links in the OSS and Pro API sections to remove unnecessary README.md suffixes, ensuring cleaner and more direct navigation to the documentation. This update aims to enhance the clarity and usability of the API documentation. * ignore mailto links * Don't check local urls * Fix SDK docs links * Fix SDK docs links * Update CI checker script * Enhance GitHub Actions workflow for link checking - Updated the check-links.yml workflow to ignore changes in the 'src' and 'tests' directories, as well as Python files, during push and pull request events on the main branch. This aims to streamline the link checking process by focusing on relevant changes only. This update improves the efficiency of the CI workflow by reducing unnecessary checks. * Handle backslashes in docs better * Fix links broken in projects renaming * Fix broken links * Link checker in CI should actually fail now * Update documentation links for clarity and accuracy - Changed the reference from the "starter guide" to the "production guide" in the migration guide. - Updated the service connector link to point to the correct section on infrastructure deployment in the remote storage documentation. - Minor formatting adjustment in the workspaces documentation for consistency. These changes ensure that users have access to the most relevant and accurate resources. * Refine paths-ignore syntax in CI workflow - Updated the paths-ignore entries in the check-links.yml workflow to use double quotes for consistency. - Ensured that the Python version is specified with double quotes as well. These changes enhance the readability and maintainability of the workflow configuration. * Fix the backslash problem (#3439) * Refactor documentation for clarity - Removed unnecessary line breaks in the PyTorch integration documentation, enhancing readability and ensuring a smoother flow of information. - This change aims to improve the overall user experience when navigating the component guide. * Fix some backslashes * Fix remaining backslashes * Fix line break * GITBOOK-1: Updating Pro pages with new structure, images, and steppers * GITBOOK-5: Adding the introductory text back to the main page * GITBOOK-6: No subject * GITBOOK-2: No subject * GITBOOK-2: No subject * Add Deployments section to table of contents * Optimised images with calibre/image-actions * Update ZenML Pro feature sign-up links in templates * Update ZenML Pro hierarchy documentation * GITBOOK-3: No subject * Optimised images with calibre/image-actions * GITBOOK-2: No subject * Update ZenML Pro links in deployment and access management guides * Update AWS and Databricks links in documentation * Update SDK and Deepchecks links in documentation * Update links for Linux and OpenAI API key in docs * Reflect Deepchecks integration with ZenML and SDK updates * GITBOOK-6: No subject * GITBOOK-7: No subject * Update API documentation to improve clarity and consistency * Update API reference links in READMEs * Fix GH Action for link checking (#3448) * Enhance GitHub Actions workflow by initializing FAILED variable for better error handling in link checks * Refine GitHub Actions workflow to ensure link checks report errors correctly by adding failure handling for absolute and relative link checks * try again * and another * Add comments to PR * bump versions * Refine GitHub Actions workflow to improve link check error handling by preventing immediate exit on failure and adding a reporting step after posting comments. * Update GitHub Actions workflow to standardise quotes and enhance summary comment generation for link checks * Fix date display on PR output * GITBOOK-3: No subject * GITBOOK-4: No subject * Optimised images with calibre/image-actions * Update API token and API documentation links * Optimised images with calibre/image-actions * GITBOOK-3: No subject * Auto-update of Starter template * Update org_hierarchy_pro.png asset image * Optimised images with calibre/image-actions * Add projects to ZenML Pro workspaces * Add instructions for using projects and workspaces with CLI * Update project login instructions in CLI documentation * Fix typo in hierarchy file name- Rename 'heirarchy.md' to 'hierarchy.md' in file paths * Optimised images with calibre/image-actions * Remove deprecated methods from ZenML Client documentation * Update title to capitalize in hierarchy.md * Update ZenML Pro features and deployment options * Update heading to title case in TOC.md file * Update terminology from "tenant" to "workspace" in ZenML Pro * Refactor roles and workspaces documentation formatting * Add note about creating custom organization roles via API * Add organization hierarchy diagram for ZenML Pro * Optimised images with calibre/image-actions * Update asset path and note in hierarchy.md * GITBOOK-5: No subject * Optimised images with calibre/image-actions --------- Co-authored-by: Alex Strick van Linschoten <[email protected]> Co-authored-by: Alex Strick van Linschoten <[email protected]> Co-authored-by: Zuri Negrín <[email protected]> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: GitHub Actions <[email protected]> (cherry picked from commit 2eece44)
1 parent 6725586 commit 32e3d79

File tree

498 files changed

+7472
-3438
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

498 files changed

+7472
-3438
lines changed

.github/workflows/check-links.yml

Lines changed: 161 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,161 @@
1+
---
2+
name: Check Links
3+
on:
4+
workflow_dispatch:
5+
push:
6+
branches: [main]
7+
paths-ignore: [src/**, tests/**, '**.py']
8+
pull_request:
9+
types: [opened, synchronize, reopened]
10+
paths-ignore: [src/**, tests/**, '**.py']
11+
concurrency:
12+
# New commit on branch cancels running workflows of the same branch
13+
group: ${{ github.workflow }}-${{ github.ref }}
14+
cancel-in-progress: true
15+
jobs:
16+
check-absolute-links:
17+
if: github.event.pull_request.draft == false
18+
runs-on: ubuntu-latest
19+
outputs:
20+
exit_code: ${{ steps.check-absolute.outputs.exit_code }}
21+
steps:
22+
- name: Checkout Repository
23+
uses: actions/checkout@v4
24+
- name: Set up Python
25+
uses: actions/setup-python@v4
26+
with:
27+
python-version: '3.11'
28+
- name: Install dependencies
29+
run: pip install requests
30+
- name: Check Absolute Links
31+
id: check-absolute
32+
run: |
33+
# Only check absolute links (http/https), not relative links
34+
python docs/link_checker.py --dir docs/book --substring "http" --validate-links --timeout 15 --ci-mode
35+
# Capture the exit code even if the command fails
36+
EXIT_CODE=$?
37+
echo "exit_code=$EXIT_CODE" >> $GITHUB_OUTPUT
38+
# Don't exit with error yet, as we want to keep the exit code for the summary step
39+
exit 0
40+
- name: Mark job status based on check result
41+
if: steps.check-absolute.outputs.exit_code != '0'
42+
run: |
43+
echo "::error::Absolute links check failed! Found broken links."
44+
exit 1
45+
check-relative-links:
46+
if: github.event.pull_request.draft == false
47+
runs-on: ubuntu-latest
48+
outputs:
49+
exit_code: ${{ steps.check-relative.outputs.exit_code }}
50+
steps:
51+
- name: Checkout Repository
52+
uses: actions/checkout@v4
53+
- name: Set up Python
54+
uses: actions/setup-python@v4
55+
with:
56+
python-version: '3.11'
57+
- name: Check Relative Links
58+
id: check-relative
59+
run: |
60+
# Check if relative links resolve within the repository
61+
python scripts/check_relative_links.py --dir docs/book
62+
# Capture the exit code even if the command fails
63+
EXIT_CODE=$?
64+
echo "exit_code=$EXIT_CODE" >> $GITHUB_OUTPUT
65+
# Don't exit with error yet, as we want to keep the exit code for the summary step
66+
exit 0
67+
- name: Mark job status based on check result
68+
if: steps.check-relative.outputs.exit_code != '0'
69+
run: |
70+
echo "::error::Relative links check failed! Found broken links."
71+
exit 1
72+
post-summary:
73+
needs: [check-absolute-links, check-relative-links]
74+
if: always() && github.event.pull_request.draft == false
75+
runs-on: ubuntu-latest
76+
steps:
77+
- name: Create Summary
78+
id: create-summary
79+
run: |
80+
echo "# Documentation Link Check Results" >> $GITHUB_STEP_SUMMARY
81+
82+
# Initialize FAILED variable
83+
FAILED=false
84+
85+
# Create summary content for PR comment
86+
cat << 'EOL' > comment_beginning.txt
87+
## Documentation Link Check Results
88+
EOL
89+
90+
# Check for failures in absolute links job
91+
if [[ "${{ needs.check-absolute-links.outputs.exit_code }}" != "0" ]]; then
92+
echo "❌ **Absolute links check failed**" >> $GITHUB_STEP_SUMMARY
93+
echo "There are broken absolute links in the documentation. Please check the job logs for details." >> $GITHUB_STEP_SUMMARY
94+
cat << 'EOL' > comment_absolute.txt
95+
❌ **Absolute links check failed**
96+
There are broken absolute links in the documentation. [See workflow logs for details](https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }})
97+
EOL
98+
FAILED=true
99+
else
100+
echo "✅ **Absolute links check passed**" >> $GITHUB_STEP_SUMMARY
101+
cat << 'EOL' > comment_absolute.txt
102+
✅ **Absolute links check passed**
103+
EOL
104+
fi
105+
106+
# Check for failures in relative links job
107+
if [[ "${{ needs.check-relative-links.outputs.exit_code }}" != "0" ]]; then
108+
echo "❌ **Relative links check failed**" >> $GITHUB_STEP_SUMMARY
109+
echo "There are broken relative links in the documentation. Please check the job logs for details." >> $GITHUB_STEP_SUMMARY
110+
cat << 'EOL' > comment_relative.txt
111+
❌ **Relative links check failed**
112+
There are broken relative links in the documentation. [See workflow logs for details](https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }})
113+
EOL
114+
FAILED=true
115+
else
116+
echo "✅ **Relative links check passed**" >> $GITHUB_STEP_SUMMARY
117+
cat << 'EOL' > comment_relative.txt
118+
✅ **Relative links check passed**
119+
EOL
120+
fi
121+
122+
# Add timestamp
123+
cat << EOL > comment_footer.txt
124+
<sub>Last checked: $(date -u '+%Y-%m-%d %H:%M:%S UTC')</sub>
125+
EOL
126+
127+
# Combine all parts
128+
cat comment_beginning.txt comment_absolute.txt comment_relative.txt comment_footer.txt > full_comment.txt
129+
130+
# Save comment body to output
131+
echo "comment_body<<EOF" >> $GITHUB_OUTPUT
132+
cat full_comment.txt >> $GITHUB_OUTPUT
133+
echo "EOF" >> $GITHUB_OUTPUT
134+
135+
# Save failed status to output
136+
echo "failed=$FAILED" >> $GITHUB_OUTPUT
137+
138+
# Do not exit with error - we want to post the comment first
139+
- name: Find Comment
140+
uses: peter-evans/find-comment@v3
141+
if: github.event_name == 'pull_request'
142+
id: find-comment
143+
with:
144+
issue-number: ${{ github.event.pull_request.number }}
145+
comment-author: github-actions[bot]
146+
body-includes: Documentation Link Check Results
147+
- name: Create or Update Comment
148+
uses: peter-evans/create-or-update-comment@v4
149+
if: github.event_name == 'pull_request'
150+
with:
151+
comment-id: ${{ steps.find-comment.outputs.comment-id }}
152+
issue-number: ${{ github.event.pull_request.number }}
153+
body: ${{ steps.create-summary.outputs.comment_body }}
154+
edit-mode: replace
155+
156+
# This step runs after comment is posted and fails the workflow if links are broken
157+
- name: Report Link Check Status
158+
if: steps.create-summary.outputs.failed == 'true'
159+
run: |-
160+
echo "::error::One or more link checks failed. Please fix the broken links."
161+
exit 1

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,7 @@ And finally, here are some other examples and use cases for inspiration:
266266

267267
1. [E2E Batch Inference](examples/e2e/): Feature engineering, training, and inference pipelines for tabular machine learning.
268268
2. [Basic NLP with BERT](examples/e2e_nlp/): Feature engineering, training, and inference focused on NLP.
269-
3. [LLM RAG Pipeline with Langchain and OpenAI](https://github.com/zenml-io/zenml-projects/tree/main/llm-agents): Using Langchain to create a simple RAG pipeline.
269+
3. [LLM RAG Pipeline with Langchain and OpenAI](https://github.com/zenml-io/zenml-projects/tree/main/zenml-support-agent): Using Langchain to create a simple RAG pipeline.
270270
4. [Huggingface Model to Sagemaker Endpoint](https://github.com/zenml-io/zenml-projects/tree/main/huggingface-sagemaker): Automated MLOps on Amazon Sagemaker and HuggingFace
271271
5. [LLMops](https://github.com/zenml-io/zenml-projects/tree/main/llm-complete-guide): Complete guide to do LLM with ZenML
272272

@@ -341,8 +341,8 @@ our GitHub repo.
341341
## 📚 LLM-focused Learning Resources
342342

343343
1. [LL Complete Guide - Full RAG Pipeline](https://github.com/zenml-io/zenml-projects/tree/main/llm-complete-guide) - Document ingestion, embedding management, and query serving
344-
2. [LLM Fine-Tuning Pipeline](https://github.com/zenml-io/zenml-projects/tree/main/llm-finetuning) - From data prep to deployed model
345-
3. [LLM Agents Example](https://github.com/zenml-io/zenml-projects/tree/main/llm-agents) - Track conversation quality and tool usage
344+
2. [LLM Fine-Tuning Pipeline](https://github.com/zenml-io/zenml-projects/tree/main/zencoder) - From data prep to deployed model
345+
3. [LLM Agents Example](https://github.com/zenml-io/zenml-projects/tree/main/zenml-support-agent) - Track conversation quality and tool usage
346346

347347
## 🤖 AI-Friendly Documentation with llms.txt
348348

docs/README.md

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,62 @@ rm -rf src/zenml/zen_stores/migrations/script.py.mako
4747
running it from elsewhere can lead to unexpected errors. This script will compose the docs hierarchy
4848
and serve it (http://127.0.0.1:<PORT>/).
4949

50+
## Link Checker Tool
51+
52+
The `link_checker.py` script is a utility tool for managing and validating links in our documentation.
53+
It helps maintain the quality of our documentation by:
54+
55+
* Finding broken or outdated links
56+
* Converting relative links to absolute URLs
57+
* Validating link accessibility
58+
* Supporting both directory-wide and file-specific scanning
59+
60+
### Usage
61+
62+
The script supports several modes of operation:
63+
64+
```bash
65+
# Find all links containing 'docs.zenml.io' in a directory
66+
python link_checker.py --dir docs/book --substring docs.zenml.io
67+
68+
# Check specific files for links containing 'how-to'
69+
python link_checker.py --files file1.md file2.md --substring how-to
70+
71+
# Preview link replacements without making changes
72+
python link_checker.py --files file1.md --replace-links --dry-run
73+
74+
# Replace and validate links
75+
python link_checker.py --files file1.md --replace-links --validate-links
76+
77+
# Transform paths using custom URL mappings
78+
python link_checker.py --dir docs/book --replace-links --url-mapping user-guide=user-guides
79+
```
80+
81+
### Features
82+
83+
1. **Link Detection**:
84+
- Scans for various link types (inline, reference-style, HTML, bare URLs)
85+
- Supports substring-based filtering
86+
- Works with both directories and individual files
87+
88+
2. **Link Transformation**:
89+
- Converts relative documentation links to absolute URLs
90+
- Handles README.md files and various link formats
91+
- Preserves fragments and query parameters
92+
- Supports custom URL path mappings to transform specific path segments
93+
94+
3. **Link Validation**:
95+
- Validates links via HTTP requests
96+
- Parallel validation for better performance
97+
- Detailed error reporting
98+
99+
### Requirements
100+
101+
For link validation functionality, the `requests` package is required:
102+
```bash
103+
pip install requests
104+
```
105+
50106
## Contributors
51107

52108
We welcome and recognize all contributions. You can see a list of current contributors [here](https://github.com/zenml-io/zenml/graphs/contributors).
74.6 KB
Loading
74.4 KB
Loading
74.3 KB
Loading
131 KB
Loading
74.5 KB
Loading
142 KB
Loading
153 KB
Loading

0 commit comments

Comments
 (0)