Connecting to Your Resources¶
Every resource in Featrix — foundation models, predictors, projects, jobs, endpoints — has a unique identifier. The Featrix UI shows you the exact code to access any resource you're looking at, so you can copy-paste it directly into your notebook, script, or agent prompt and know you're working with the right object.
The Problem This Solves¶
When you're staring at a model in the UI and you want to use it in code, you need to answer: which model is this, exactly? Names can be ambiguous — you might have "churn-model" in three different projects. UUIDs are unambiguous, but they're hard to type from memory.
Featrix solves this by putting copy-pasteable code snippets directly in the UI, next to every resource. You see a foundation model? The UI shows you:
Copy it. Paste it into your notebook. You're now guaranteed to be talking to the exact model you were looking at. No name lookups, no guessing, no "wait, which one was it?"
What the UI Shows You¶
On Every Resource Page¶
Each resource page in the Featrix UI includes a Connect panel with:
- The UUID — click to copy to clipboard
- Python code — ready-to-paste
featrixsphereSDK calls - TypeScript code — equivalent
featrixsphere-tscalls - curl command — raw REST API call
- Deep link — shareable URL that takes anyone directly to this resource
Foundation Model Page¶
# Python — copy from the UI
from featrixsphere import FeatrixSphere
featrix = FeatrixSphere()
fm = featrix.foundational_model("550e8400-e29b-41d4-a716-446655440000")
// TypeScript — copy from the UI
import { FeatrixSphere } from 'featrixsphere-ts';
const featrix = await FeatrixSphere.create();
const fm = await featrix.foundationalModel("550e8400-e29b-41d4-a716-446655440000");
# curl — copy from the UI
curl -H "Authorization: Bearer $FEATRIX_API_KEY" \
https://sphere-api.featrix.com/compute/session/550e8400-e29b-41d4-a716-446655440000
Predictor Page¶
predictor = featrix.predictor(session_id="550e8400-...", predictor_id="7f3a2b1c-...")
# Make a prediction
result = predictor.predict({"age": 35, "income": 75000})
Published Endpoint Page¶
published = featrix.published_predictor(
org="acme",
name="churn-v3",
api_key="your-production-key"
)
result = published.predict({"customer_id": "C-1234"})
The UI fills in the real IDs, org names, and endpoint names for you. You just copy and run.
Deep Links: Share What You're Looking At¶
Every resource has a shareable URL:
| Type | Example |
|---|---|
| Organization | https://app.featrix.com/goto/org/acme |
| Project | https://app.featrix.com/goto/project/sales-forecasting |
| Foundation Model | https://app.featrix.com/goto/foundation/550e8400-... |
| Model (Predictor) | https://app.featrix.com/goto/model/churn-predictor |
| Job | https://app.featrix.com/goto/job/7f3a2b1c-... |
| Prediction Endpoint | https://app.featrix.com/goto/prediction/churn-endpoint |
You can use names or UUIDs as the identifier — Featrix resolves either. If the resource belongs to a different organization than your current one, your active org is switched automatically.
Use case: Paste a deep link into Slack, a Jira ticket, a notebook comment, or an agent prompt. Anyone who clicks it lands on exactly the resource you meant.
UUIDs: The Unambiguous Identifier¶
Every Featrix resource has a UUID (e.g., 550e8400-e29b-41d4-a716-446655440000). UUIDs are:
- Immutable — they never change, even if you rename the resource
- Globally unique — no two resources share a UUID, across all orgs
- Copy-pasteable — click the UUID in the UI to copy it to your clipboard
Always use UUIDs in automation
Names are for humans. UUIDs are for code. When writing scripts, CI/CD pipelines, or agent prompts, always use the UUID. Names can change; UUIDs can't.
Searching by UUID¶
You can paste a UUID into the Featrix UI search bar to jump directly to any resource. This is especially useful when you're debugging — you see a UUID in a log file, paste it into search, and immediately see what it is.
Programmatic Access: Full Reference¶
Python SDK (featrixsphere)¶
from featrixsphere import FeatrixSphere
# Reads API key from ~/.featrix or FEATRIX_API_KEY env var
featrix = FeatrixSphere()
| What you want | Code |
|---|---|
| Verify identity | featrix.whoami() |
| Get a foundation model | featrix.foundational_model("uuid") |
| List all foundation models | featrix.list_sessions() |
| Filter by name | featrix.list_sessions(name_prefix="sales") |
| Get a predictor | featrix.predictor(session_id="uuid") |
| List predictors on a FM | fm.list_predictors() |
| Set active project | featrix.set_current_project("project-name") |
| Get model card | fm.get_model_card() |
| Make a prediction | predictor.predict({"col": "value"}) |
| Batch predict | predictor.batch_predict([{"col": "val"}, ...]) |
| Explain a prediction | predictor.explain({"col": "value"}) |
| Submit ground truth | featrix.prediction_feedback(prediction_uuid="uuid", ground_truth="label") |
| Access published model | featrix.published_predictor(org="acme", name="model", api_key="key") |
| Create API endpoint | predictor.create_api_endpoint(name="endpoint-name") |
| Wait for training | fm.wait_for_training() or predictor.wait_for_training() |
TypeScript SDK (featrixsphere-ts)¶
import { FeatrixSphere } from 'featrixsphere-ts';
const featrix = await FeatrixSphere.create({ apiKey: 'your-key' });
| What you want | Code |
|---|---|
| Verify identity | await featrix.whoami() |
| Get a foundation model | await featrix.foundationalModel("uuid") |
| List all foundation models | await featrix.listSessions() |
| Get a predictor | await featrix.predictor("session-uuid") |
| Set active project | await featrix.setCurrentProject("project-name") |
| Make a prediction | await predictor.predict({col: "value"}) |
| Batch predict | await predictor.batchPredict([{col: "val"}, ...]) |
| Explain a prediction | await predictor.explain({col: "value"}) |
End-to-End: UI to Code to Production¶
1. You train a foundation model in the UI. When it's done, you see the model page with its UUID, metrics, and code snippets.
2. You copy the code snippet into your notebook:
fm = featrix.foundational_model("550e8400-e29b-41d4-a716-446655440000")
predictor = fm.create_binary_classifier(
name="churn-v3",
target_column="churned",
)
predictor = predictor.wait_for_training()
print(f"AUC: {predictor.auc}, F1: {predictor.f1}")
3. You share the predictor link with your team for review:
4. Your teammate opens the link, sees the predictor page, copies the prediction code, and tests it:
predictor = featrix.predictor(session_id="550e8400-...", predictor_id="7f3a2b1c-...")
result = predictor.predict({"tenure_months": 3, "monthly_spend": 29.99})
5. You deploy to production and give agents the endpoint:
endpoint = predictor.create_api_endpoint(name="churn-v3-prod")
# An agent uses the published predictor
published = featrix.published_predictor(org="acme", name="churn-v3-prod", api_key="agent-key")
result = published.predict(customer_record)
At every step, you copied code from the UI. At every step, the UUID guaranteed you were working with the exact right object.
Safety and Access Control¶
- Authentication required — all deep links require login; API access requires a valid API key
- Organization scoping — resources belong to orgs; API keys can only access their own org's resources
- Verify before automating — use
featrix.whoami()to confirm you're in the right org before running batch operations - UUIDs over names — names can change and collide across projects; UUIDs are permanent and unique
- Prediction feedback — use
prediction_feedback()with the prediction UUID to close the monitoring loop and detect drift
# Always verify you're in the right place
identity = featrix.whoami()
print(f"Org: {identity['org_name']}, User: {identity['user_id']}")
Tips¶
- Click any UUID in the UI to copy it to your clipboard
- Paste a UUID into UI search to jump to any resource
- Names are case-insensitive in deep links —
/goto/project/My%20Projectand/goto/project/my%20projectboth work - Store your API key in
~/.featrixorFEATRIX_API_KEYenv var so you don't pass it every time - Use
%20for spaces in deep link URLs (e.g.,/goto/project/Sales%20Model)