Skip to content

Commit 046176f

Browse files
committed
Pairing with mlflow==3.11.1
1 parent 68537c7 commit 046176f

33 files changed

Lines changed: 3569 additions & 45 deletions

.github/workflows/CI.yml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,8 @@ jobs:
1414
max-parallel: 1
1515
matrix:
1616
version:
17-
- '1.10'
18-
- '1.11'
19-
- '1' # automatically expands to the latest stable 1.x release of Julia.
17+
- 'lts'
18+
- '1'
2019
os:
2120
- ubuntu-latest
2221
arch:
@@ -27,7 +26,7 @@ jobs:
2726
if: hashFiles('**/requirements.txt', '**/pyproject.toml') == ''
2827
run: |
2928
touch ./requirements.txt
30-
echo "mlflow[auth]==3.2.0" > ./requirements.txt
29+
echo "mlflow[auth]==3.11.1" > ./requirements.txt
3130
- uses: actions/setup-python@v4
3231
with:
3332
python-version: '3.12.3'

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ UUIDs = "cf7118a7-6976-5b1a-9a39-7adc72f591a4"
1515
[compat]
1616
Base64 = "1.0"
1717
HTTP = "1.0"
18-
JSON = "0.21,1"
18+
JSON = "1.5.0"
1919
ShowCases = "0.1"
2020
URIs = "1.0"
2121
julia = "1.0"

README.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,13 @@
44
[![Build Status](https://github.com/JuliaAI/MLFlowClient.jl/actions/workflows/CI.yml/badge.svg?branch=main)](https://github.com/JuliaAI/MLFlowClient.jl/actions/workflows/CI.yml?query=branch%3Amain)
55
[![Coverage](https://codecov.io/gh/JuliaAI/MLFlowClient.jl/branch/main/graph/badge.svg)](https://codecov.io/gh/JuliaAI/MLFlowClient.jl)
66

7-
Julia client for [MLFlow](https://www.mlflow.org/) `3.2.0`. Use with later versions at
8-
your own risk. For example, there is [this known
9-
issue](https://github.com/JuliaAI/MLFlowClient.jl/issues/76).
7+
Julia client for [MLFlow](https://www.mlflow.org/). Ensured compatibility with `mlflow==3.11.1`.
108

119
- [x] Supports tracking of metrics, parameters, tags, artifacts, and models.
1210
- [x] Compatible with latest MLFlow server capabilities.
1311
- [x] Mirroring types from MLFlow API for easy use.
1412
- [x] Includes MLflow Authentication REST API interface.
15-
- [ ] Supports artifact download/upload.
13+
- [x] Supports artifact download/upload and multipart uploads.
14+
- [x] Supports Scorers API for evaluation.
15+
- [x] Supports Gateway API (secrets, model definitions, endpoints, budgets).
16+
- [x] Supports Prompt Optimization API.

docs/make.jl

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ makedocs(;
1313
"Run operations" => "reference/run.md",
1414
"Registered model operations" => "reference/registered_model.md",
1515
"Model version operations" => "reference/model_version.md",
16-
"User operations" => "reference/user.md",]])
16+
"User operations" => "reference/user.md",
17+
"Scorer operations" => "reference/scorer.md",
18+
"Gateway operations" => "reference/gateway.md",
19+
"Prompt optimization operations" => "reference/prompt_optimization.md"]])
1720

1821
deploydocs(; repo="github.com/JuliaAI/MLFlowClient.jl", devbranch="main")

docs/src/reference/artifact.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,12 @@
11
# Artifact operations
22
```@docs
33
listartifacts
4+
listartifactsdirect
5+
downloadartifact
6+
uploadartifact
7+
deleteartifact
8+
createmultipartupload
9+
completemultipartupload
10+
abortmultipartupload
11+
getpresigneddownloadurl
412
```

docs/src/reference/gateway.md

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
# Gateway operations
2+
## Secrets
3+
```@docs
4+
creategatewaysecret
5+
getgatewaysecretinfo
6+
updategatewaysecret
7+
deletegatewaysecret
8+
listgatewaysecretinfos
9+
```
10+
11+
## Model Definitions
12+
```@docs
13+
creategatewaymodeldefinition
14+
getgatewaymodeldefinition
15+
listgatewaymodeldefinitions
16+
updategatewaymodeldefinition
17+
deletegatewaymodeldefinition
18+
```
19+
20+
## Endpoints
21+
```@docs
22+
creategatewayendpoint
23+
getgatewayendpoint
24+
updategatewayendpoint
25+
deletegatewayendpoint
26+
listgatewayendpoints
27+
attachmodeltogatewayendpoint
28+
detachmodelfromgatewayendpoint
29+
setgatewayendpointtag
30+
deletegatewayendpointtag
31+
```
32+
33+
## Endpoint Bindings
34+
```@docs
35+
creategatewayendpointbinding
36+
deletegatewayendpointbinding
37+
listgatewayendpointbindings
38+
```
39+
40+
## Budgets
41+
```@docs
42+
creategatewaybudget
43+
getgatewaybudget
44+
updategatewaybudget
45+
deletegatewaybudget
46+
listgatewaybudgets
47+
listgatewaybudgetwindows
48+
```
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# Prompt optimization operations
2+
```@docs
3+
createpromptoptimizationjob
4+
getpromptoptimizationjob
5+
searchpromptoptimizationjobs
6+
cancelpromptoptimizationjob
7+
deletepromptoptimizationjob
8+
```

docs/src/reference/scorer.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# Scorer operations
2+
```@docs
3+
registerscorer
4+
listscorers
5+
listscorerversions
6+
getscorer
7+
deletescorer
8+
```

docs/src/reference/types.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,25 @@ RunInputs
1818
User
1919
ExperimentPermission
2020
RegisteredModelPermission
21+
Scorer
22+
GatewaySecretInfo
23+
GatewayModelDefinition
24+
GatewayEndpoint
25+
GatewayEndpointConfig
26+
GatewayEndpointBinding
27+
GatewayEndpointModelConfig
28+
GatewayEndpointModelMapping
29+
GatewayEndpointTag
30+
GatewayBudgetWindow
31+
GatewayBudgetPolicy
32+
BudgetDuration
33+
FallbackConfig
34+
MultipartUploadCredential
35+
MultipartUploadPart
36+
PromptOptimizationJob
37+
PromptOptimizationJobConfig
38+
PromptOptimizationJobTag
39+
InitialEvalScoresEntry
40+
FinalEvalScoresEntry
41+
JobStateInfo
2142
```

src/MLFlowClient.jl

Lines changed: 51 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
for working with [MLFlow](https://mlflow.org/) using the REST
66
[API v2.0](https://www.mlflow.org/docs/latest/rest-api.html).
77
8-
`MLFlowClient` allows you to create and manage `MLFlow` experiments, runs, and log metrics
8+
`MLFlowClient` allows you to create and manage `MLFlow` experiments, runs, and log parameters, metrics,
99
and artifacts. If you are not familiar with `MLFlow` and its concepts, please refer to
1010
[MLFlow documentation](https://mlflow.org/docs/latest/index.html).
1111
"""
@@ -26,13 +26,16 @@ include("types/tag.jl")
2626
export Tag
2727

2828
include("types/enums.jl")
29-
export ViewType, RunStatus, ModelVersionStatus, Permission, DeploymentJobRunState, State
29+
export ViewType, RunStatus, ModelVersionStatus, Permission, DeploymentJobRunState, State,
30+
WebhookStatus, WebhookEvent, JobState, OptimizerType,
31+
RoutingStrategy, FallbackStrategy, BudgetUnit, BudgetDurationUnit,
32+
BudgetTargetScope, BudgetAction, GatewayModelLinkageType
3033

3134
include("types/dataset.jl")
3235
export Dataset, DatasetInput
3336

3437
include("types/artifact.jl")
35-
export FileInfo
38+
export FileInfo, MultipartUploadCredential, MultipartUploadPart
3639

3740
include("types/model.jl")
3841
export ModelInput, ModelMetric, ModelOutput, ModelParam, ModelVersion,
@@ -45,17 +48,34 @@ include("types/experiment.jl")
4548
export Experiment, ExperimentPermission
4649

4750
include("types/run.jl")
48-
export Run, Param, Metric, RunData, RunInfo, RunInputs
51+
export Run, Param, Metric, RunData, RunInfo, RunInputs, RunOutputs
4952

5053
include("types/user.jl")
5154
export User
5255

56+
include("types/webhook.jl")
57+
export Webhook, WebhookTestResult, WebhookEntity, WebhookAction, WebhookEvent
58+
59+
include("types/scorer.jl")
60+
export Scorer
61+
62+
include("types/gateway.jl")
63+
export GatewaySecretInfo, GatewayModelDefinition, GatewayEndpoint, GatewayEndpointConfig,
64+
GatewayEndpointBinding, GatewayBudgetWindow,
65+
FallbackConfig, BudgetDuration, GatewayEndpointModelConfig,
66+
GatewayEndpointModelMapping, GatewayEndpointTag, GatewayBudgetPolicy
67+
68+
include("types/prompt_optimization.jl")
69+
export PromptOptimizationJob, PromptOptimizationJobConfig, PromptOptimizationJobTag,
70+
InitialEvalScoresEntry, FinalEvalScoresEntry, JobStateInfo
71+
5372
include("api.jl")
5473

5574
include("utils.jl")
5675

5776
include("services/experiment.jl")
5877
export getexperiment, createexperiment, deleteexperiment, setexperimenttag,
78+
deleteexperimenttag,
5979
updateexperiment, restoreexperiment, searchexperiments, getexperimentbyname,
6080
createexperimentpermission, getexperimentpermission, updateexperimentpermission,
6181
deleteexperimentpermission
@@ -68,7 +88,9 @@ include("services/logger.jl")
6888
export logbatch, loginputs, logmetric, logmodel, logparam
6989

7090
include("services/artifact.jl")
71-
export listartifacts
91+
export listartifacts, downloadartifact, uploadartifact, listartifactsdirect,
92+
deleteartifact, createmultipartupload, completemultipartupload,
93+
abortmultipartupload, getpresigneddownloadurl
7294

7395
include("services/misc.jl")
7496
export refresh, getmetrichistory
@@ -84,9 +106,32 @@ include("services/model_version.jl")
84106
export getlatestmodelversions, getmodelversion, createmodelversion, deletemodelversion,
85107
updatemodelversion, searchmodelversions, getdownloaduriformodelversionartifacts,
86108
transitionmodelversionstage, setmodelversiontag, deletemodelversiontag,
87-
getmodelversionbyalias
109+
getmodelversionbyalias, listmodelversionartifacts
88110

89111
include("services/user.jl")
90112
export createuser, getuser, updateuserpassword, updateuseradmin, deleteuser
91113

114+
include("services/webhook.jl")
115+
export createwebhook, getwebhook, listwebhooks, updatewebhook, deletewebhook, testwebhook
116+
117+
include("services/scorer.jl")
118+
export registerscorer, listscorers, listscorerversions, getscorer, deletescorer
119+
120+
include("services/gateway.jl")
121+
export creategatewaysecret, getgatewaysecretinfo, updategatewaysecret, deletegatewaysecret,
122+
listgatewaysecretinfos,
123+
creategatewaymodeldefinition, getgatewaymodeldefinition, listgatewaymodeldefinitions,
124+
updategatewaymodeldefinition, deletegatewaymodeldefinition,
125+
creategatewayendpoint, getgatewayendpoint, updategatewayendpoint, deletegatewayendpoint,
126+
listgatewayendpoints,
127+
attachmodeltogatewayendpoint, detachmodelfromgatewayendpoint,
128+
creategatewayendpointbinding, deletegatewayendpointbinding, listgatewayendpointbindings,
129+
setgatewayendpointtag, deletegatewayendpointtag,
130+
creategatewaybudget, getgatewaybudget, updategatewaybudget, deletegatewaybudget,
131+
listgatewaybudgets, listgatewaybudgetwindows
132+
133+
include("services/prompt_optimization.jl")
134+
export createpromptoptimizationjob, getpromptoptimizationjob, searchpromptoptimizationjobs,
135+
cancelpromptoptimizationjob, deletepromptoptimizationjob
136+
92137
end

0 commit comments

Comments
 (0)