-
Notifications
You must be signed in to change notification settings - Fork 12
Conversation
Link Check ReportAll 43 links passed! |
sounds good to me @mike0sv ! |
Let's first see what extensions we have and what we want to write as docs:
I assume, eventually we would like to cover all of these. For the beginning, "deploy" and "build" probably gets the priority. In docs, these items could be subpages of User Guide, e.g.: |
Ahah, I was writing the previous comment without checking out the docs deployment to preview env. I wonder if we can merge some pages into what you generate. E.g. "Working with data" could be moved here "Data". Looks like there are not so many opportunities though, cause Models/Deployemnts/Serve/Build was already covered in GS. So we can just add a link to GS there. |
from mlem.api import save, load | ||
|
||
|
||
data, y = load_iris(return_X_y=True, as_frame=True) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wish we could auto-generate this from our tests, but not sure it's possible. We have asserts, fixtures, etc, it's going to be a challenge to remove them and make the code both working and readable.
Had a call with @aguschin, we decided to go this way: Target docs section for specific user groups. There are 4 of them:
So, we will merge We also will re-write some User Guide pages to remove internal details from them. Or completely move some pages to "Advanced Usage" (I'm looking at you, Does this make sense? |
@jorgeorpinel @shcheklein WDYT about what Mike said? |
Yep, sounds very reasonable to me, folks. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the actual work is writing those manual sections
I'm just going to leave a couple comments on one of the index pages for now (probably apply to all):
# Model extensions | ||
|
||
Model extensions add support for new types models that MLEM can covert into MLEM | ||
model objects in [`save` API method](/doc/api-reference/save) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should try to explain this at a higher level. What functionality do model extensions give to users? OK they extend MLEM model objects I think, how is that useful? Should we start with a recap of what a model object is (used for) first?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tried to address this in #188 in "Object Reference" section, e.g. see this page https://mlem-ai-new-docs-struct-hy95mv.herokuapp.com/doc/object-reference/model. If you have some feedback, you can post it here or do it in #188.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unable to leave feedback at this level in #188 atm, it's too huge.
Typicaly they will implement [ModelType](/doc/user-guide/mlem-abcs#modeltype) | ||
and [ModelIO](/doc/user-guide/mlem-abcs#modelio) interfaces. | ||
|
||
Some also implement [DataType](/doc/user-guide/mlem-abcs#datatype) interface if | ||
specific data objects are needed for model to work. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For now just a copy edit summarizing this part but let's consider (or make an issue about) auto-linking many of these ABCs as well as any other reference-like terms (commands, extensions even, other types, etc).
Typicaly they will implement [ModelType](/doc/user-guide/mlem-abcs#modeltype) | |
and [ModelIO](/doc/user-guide/mlem-abcs#modelio) interfaces. | |
Some also implement [DataType](/doc/user-guide/mlem-abcs#datatype) interface if | |
specific data objects are needed for model to work. | |
Typically they will implement [ModelType] and [ModelIO] interfaces. Some also | |
implement the [DataType] interface if specific MLEM data objects are needed for | |
model to work. | |
[modeltype]: /doc/user-guide/mlem-abcs#modeltype | |
[modelio]: /doc/user-guide/mlem-abcs#modelio | |
[datatype]: /doc/user-guide/mlem-abcs#datatype |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use first page (models/sklearn) to leave comments and change suggestions
👇🏼
@@ -0,0 +1,69 @@ | |||
# Scikit-Learn Models Support |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The URLs and titles aren't very consistent: sklearn
vs. Scikit-Learn Models Support. Consistency reduces confusion and can help SEO.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
On the other hand, it's concise, which is good to me. Easier to remember if you want to type it in URL or do something with the link.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Up to you on this. Just keep in mind URL vs page titles please 🙂 If they're different it should be a reasoned, conscious decision, I think.
[ModelType](/doc/user-guide/mlem-abcs#modeltype) implementations for any | ||
sklearn-compatible classes as well as `Pipeline` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Product questions (rhetorical i.e. these need links or better explanations IMO):
- What are sklearn-compatible classes ?
- What is
Pipeline
?
However, this intro is a bit low-level (even for a reference). It's OK to be specific about what the extension is/does but can we try to zoom out, use more general language, etc? Something like "Enables you to connect Scikit-Learn classes to MLEM by implementing a model object..." (just an idea)
## Description | ||
|
||
**TODO** |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Haven't seen any descriptions yet. Any ideas for what will be in these sections? Maybe leave it for the user guide if it's unclear now.
## Requirements | ||
|
||
```bash | ||
pip install mlem[sklearn] | ||
# or | ||
pip install scikit-learn | ||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Installation?
bash
->cli
?
## Examples | ||
|
||
### Saving and loading Scikit-Learn model |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @mike0sv and @aguschin, great analysis. I've had the chance to think and research on this topic quite a bit and my view is somewhat different although the logic is similar. PTAL at this proposed framework. However that conversation goes beyond the scope of this PR (mainly a class reference IMO) so I'll post a hidden answer down here but let's move it elsewhere after that? In the proposed docs framework, we work with conceptual levels and expected traffic (along with other properties) instead of audiences (but again, it's similar). These levels also roughly match marketing/SEO parts of the user journey (TOFU, MOFU, BOFU). Some key comparisons:
In the end we have to decide on a view so there's no precise right or wrong, and a lot of this is biased towards DVC. So we should definitely be flexible and adapt the framework to also accommodate MLEM product and docs needs. |
I see the auto-generated references as very far from this plan. "How to" guides could be a great addition but it seems like we still need the more technical references and these are different tasks so the guides should be a different PR I think. Also, I'd make a single guide per object category and use tabs to consolidate all type into a single page. |
@jorgeorpinel @mike0sv, I'm closing this PR, since we decided that everything should be done in #188. @jorgeorpinel, I'll use your feedback above for #188. |
Docs structure overhaul as discussed in #179 This PR is meant to replace #179 and #182 What was done: - Created subpages for all major features (models/data/serving/building/deploy) in user-guide for each - Moved there hand-crafted documentation from extension docs in #179 - index pages are from GS - Renamed Extension section into Object Reference - restructured it. was: `<ext type>/<ext name>`, now: `<object group>/<ext name>`. Now multipurpose extensions (eg docker has build & deploy) has two pages - Object Reference is now fully autogenerated - Added builtin implementations there too - Moved details about mlem abcs and mlem objects from UG - Rewritten GS - New User Guide pages - New Object reference index pages written - Use Cases cleaned up TODO: - [x] rewrite GS Deployment - [x] rewrite UG Deployment (+ explain what State is) - [x] update UG Heroku - [x] merge UG K8s @madhur-tandon - [x] update UG Sagemaker - @mike0sv, [there are your TODOs left](https://mlem-ai-new-docs-struct-hy95mv.herokuapp.com/doc/user-guide/deploying/sagemaker) - [x] write UG Docker @madhur-tandon - [x] update CLI reference - [x] update API reference - [x] merge UG export to venvs @madhur-tandon - [x] rewrite Project structure - [x] update UC - remote `.mlem/` dir and `mlem.api.ls` mentions - [x] search and remove all other mentions of `.mlem/` dir and `mlem.api.ls` - [x] search and update all other mentions of `mlem init` - [x] search and update all other mentions of `--conf` or `-c` - [x] fix broken links @madhur-tandon - [x] add `mlem checkenv` to command reference. Why it wasn't generated I wonder?
This is second PR for #171 (after #172); Also rel. #181
It adds separate page for each MLEM extension. For now most of them consist only of auto-generated content:
There are also two sections that are mostly empty: description and examples. They are meant to be filled manually.
However I filled them for first pages in each category (model/data/etc) just as an example.
Open questions:
User Guide
models/sklearn
) to leave comments and change suggestions so we have them all in one place. I will adapt bootstrap script and re-generate all of the pages, no need to leave them everywhere.In review app: https://mlem-ai-feature-0-3-0-e-qpg1qt.herokuapp.com/doc/extensions