File tree Expand file tree Collapse file tree 2 files changed +23
-0
lines changed
Expand file tree Collapse file tree 2 files changed +23
-0
lines changed Original file line number Diff line number Diff line change @@ -113,4 +113,16 @@ curl -X POST "http://localhost:8000/v1/chat/completions" \\
113113 ]
114114 }'` ) ;
115115 } ) ;
116+
117+ it ( "docker model runner" , async ( ) => {
118+ const { snippet : snippetFunc } = LOCAL_APPS [ "docker-model-runner" ] ;
119+ const model : ModelData = {
120+ id : "bartowski/Llama-3.2-3B-Instruct-GGUF" ,
121+ tags : [ "conversational" ] ,
122+ inference : "" ,
123+ } ;
124+ const snippet = snippetFunc ( model ) ;
125+
126+ expect ( snippet ) . toEqual ( `docker model run hf.co/bartowski/Llama-3.2-3B-Instruct-GGUF:{{QUANT_TAG}}` ) ;
127+ } ) ;
116128} ) ;
Original file line number Diff line number Diff line change @@ -297,6 +297,10 @@ const snippetMlxLm = (model: ModelData): LocalAppSnippet[] => {
297297 ] ;
298298} ;
299299
300+ const snippetDockerModelRunner = ( model : ModelData , filepath ?: string ) : string => {
301+ return `docker model run hf.co/${ model . id } ${ getQuantTag ( filepath ) } ` ;
302+ } ;
303+
300304/**
301305 * Add your new local app here.
302306 *
@@ -467,6 +471,13 @@ export const LOCAL_APPS = {
467471 displayOnModelPage : isLlamaCppGgufModel ,
468472 snippet : snippetOllama ,
469473 } ,
474+ "docker-model-runner" : {
475+ prettyLabel : "Docker Model Runner" ,
476+ docsUrl : "https://docs.docker.com/ai/model-runner/" ,
477+ mainTask : "text-generation" ,
478+ displayOnModelPage : isLlamaCppGgufModel ,
479+ snippet : snippetDockerModelRunner ,
480+ } ,
470481} satisfies Record < string , LocalApp > ;
471482
472483export type LocalAppKey = keyof typeof LOCAL_APPS ;
You can’t perform that action at this time.
0 commit comments