xinference 0.7.0__py3-none-any.whl → 0.7.1__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of xinference might be problematic. Click here for more details.
- xinference/_version.py +3 -3
- xinference/api/restful_api.py +4 -4
- xinference/deploy/utils.py +3 -1
- xinference/model/embedding/__init__.py +5 -1
- xinference/model/embedding/core.py +7 -7
- xinference/model/llm/ggml/chatglm.py +7 -5
- xinference/model/llm/llm_family.py +41 -15
- xinference/model/llm/pytorch/core.py +1 -0
- xinference/model/llm/pytorch/utils.py +3 -0
- xinference/model/llm/vllm/core.py +5 -1
- xinference/model/rerank/__init__.py +5 -1
- xinference/model/rerank/core.py +7 -6
- xinference/model/utils.py +13 -2
- xinference/web/ui/build/asset-manifest.json +3 -3
- xinference/web/ui/build/index.html +1 -1
- xinference/web/ui/build/static/js/main.778615cc.js +3 -0
- xinference/web/ui/build/static/js/main.778615cc.js.map +1 -0
- xinference/web/ui/node_modules/.cache/babel-loader/35204b265d70210394b0a8571e5b01c8c0f9a748437b8a923961e3560ae3d550.json +1 -0
- xinference/web/ui/node_modules/.cache/babel-loader/483eb7e5f01e34c6a42ad7c64dad550ff945ee21053a52c2e5e7ebe108b85411.json +1 -0
- xinference/web/ui/node_modules/.cache/babel-loader/667753ce39ce1d4bcbf9a5f1a103d653be1d19d42f4e1fbaceb9b507679a52c7.json +1 -0
- xinference/web/ui/node_modules/.cache/babel-loader/6e63957e4e0801705c6cb258379bfda0007ce6c3ddd2e3b62898b68455c3edf4.json +1 -0
- xinference/web/ui/node_modules/.cache/babel-loader/8d2b0b3c6988d1894694dcbbe708ef91cfe62d62dac317031f09915ced637953.json +1 -0
- xinference/web/ui/node_modules/.cache/babel-loader/8d77975a2735d67a618407026e5325608ccd66f1b379a74faf35b4087db536f3.json +1 -0
- xinference/web/ui/node_modules/.cache/babel-loader/b374bf2be1eac3cff5e0a8528a8e816e266ece911f714c123110961798a93a3b.json +1 -0
- xinference/web/ui/node_modules/.cache/babel-loader/d8a42e9df7157de9f28eecefdf178fd113bf2280d28471b6e32a8a45276042df.json +1 -0
- xinference/web/ui/node_modules/.cache/babel-loader/ed010102f476cd1a22b49be031a7f94f2ab3dd7ba8bf58839a771d46e28ff559.json +1 -0
- xinference/web/ui/node_modules/.cache/babel-loader/fe653ca0ca4297b415c0be4013574870d0465a657ae0f3d3f5b66ef6a831390c.json +1 -0
- {xinference-0.7.0.dist-info → xinference-0.7.1.dist-info}/METADATA +1 -1
- {xinference-0.7.0.dist-info → xinference-0.7.1.dist-info}/RECORD +34 -34
- xinference/web/ui/build/static/js/main.8126d441.js +0 -3
- xinference/web/ui/build/static/js/main.8126d441.js.map +0 -1
- xinference/web/ui/node_modules/.cache/babel-loader/06eb9846159adb398d44df0b0debc256a9fd9e8171a7d68f5c4ee4d655acfa45.json +0 -1
- xinference/web/ui/node_modules/.cache/babel-loader/3bda436576ecb05f81f7b6ec475d1cfaf03e2b3066e3a75902fe6e8c4773b43b.json +0 -1
- xinference/web/ui/node_modules/.cache/babel-loader/48878f5178bad1a47757e011af41c974a7946efa29485506c4d19f25bf5d522d.json +0 -1
- xinference/web/ui/node_modules/.cache/babel-loader/59574eb63cfe9ed2e58d2f5a420e1ae54354e243a602e9bc73deae3147ed4f98.json +0 -1
- xinference/web/ui/node_modules/.cache/babel-loader/75a5abcbc92da335fdde530f5689194ec79a4b2345b8cba594f8904d3b88e3c6.json +0 -1
- xinference/web/ui/node_modules/.cache/babel-loader/84bfe7afede38da1f8ad569d891276fe4d66cfb87bf5c9ff7a113788ba62bb88.json +0 -1
- xinference/web/ui/node_modules/.cache/babel-loader/940ed05006583b955894e2b8f65a4a5ebf34f8149d747f59fae5131f17d65482.json +0 -1
- xinference/web/ui/node_modules/.cache/babel-loader/9c5f03db9aa88582a9b69b25c7f1acc78ba7fc61f743c9ed7399abb292d5dbde.json +0 -1
- xinference/web/ui/node_modules/.cache/babel-loader/c02e70e9b9efcf3bd056606308104308d6a6ac559f2bc0b4454c11fb5874457c.json +0 -1
- xinference/web/ui/node_modules/.cache/babel-loader/e610aefd7000a3f8542a25cb66c64671cc8da18350de4e5b577102ba4bb78d65.json +0 -1
- /xinference/web/ui/build/static/js/{main.8126d441.js.LICENSE.txt → main.778615cc.js.LICENSE.txt} +0 -0
- {xinference-0.7.0.dist-info → xinference-0.7.1.dist-info}/LICENSE +0 -0
- {xinference-0.7.0.dist-info → xinference-0.7.1.dist-info}/WHEEL +0 -0
- {xinference-0.7.0.dist-info → xinference-0.7.1.dist-info}/entry_points.txt +0 -0
- {xinference-0.7.0.dist-info → xinference-0.7.1.dist-info}/top_level.txt +0 -0
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"ast":null,"code":"import _objectSpread from\"/home/runner/work/inference/inference/xinference/web/ui/node_modules/@babel/runtime/helpers/esm/objectSpread2.js\";import _slicedToArray from\"/home/runner/work/inference/inference/xinference/web/ui/node_modules/@babel/runtime/helpers/esm/slicedToArray.js\";import DeleteOutlineOutlinedIcon from'@mui/icons-material/DeleteOutlineOutlined';import OpenInBrowserOutlinedIcon from'@mui/icons-material/OpenInBrowserOutlined';import{TabContext,TabList,TabPanel}from'@mui/lab';import{Box,Stack,Tab}from'@mui/material';import{DataGrid}from'@mui/x-data-grid';import React,{useContext,useEffect,useState}from'react';import{ApiContext}from'../../components/apiContext';import Title from'../../components/Title';import{jsx as _jsx}from\"react/jsx-runtime\";import{jsxs as _jsxs}from\"react/jsx-runtime\";var RunningModels=function RunningModels(){var _React$useState=React.useState('1'),_React$useState2=_slicedToArray(_React$useState,2),tabValue=_React$useState2[0],setTabValue=_React$useState2[1];var _useState=useState([]),_useState2=_slicedToArray(_useState,2),llmData=_useState2[0],setLlmData=_useState2[1];var _useState3=useState([]),_useState4=_slicedToArray(_useState3,2),embeddingModelData=_useState4[0],setEmbeddingModelData=_useState4[1];var _useState5=useState([]),_useState6=_slicedToArray(_useState5,2),imageModelData=_useState6[0],setImageModelData=_useState6[1];var _useState7=useState([]),_useState8=_slicedToArray(_useState7,2),rerankModelData=_useState8[0],setRerankModelData=_useState8[1];var _useContext=useContext(ApiContext),isCallingApi=_useContext.isCallingApi,setIsCallingApi=_useContext.setIsCallingApi;var _useContext2=useContext(ApiContext),isUpdatingModel=_useContext2.isUpdatingModel,setIsUpdatingModel=_useContext2.setIsUpdatingModel;var endPoint=useContext(ApiContext).endPoint;var handleTabChange=function handleTabChange(event,newValue){setTabValue(newValue);};var update=function update(isCallingApi){if(isCallingApi){setLlmData([{id:'Loading, do not refresh page...',url:'IS_LOADING'}]);setEmbeddingModelData([{id:'Loading, do not refresh page...',url:'IS_LOADING'}]);setImageModelData([{id:'Loading, do not refresh page...',url:'IS_LOADING'}]);setRerankModelData([{id:'Loading, do not refresh page...',url:'IS_LOADING'}]);}else{setIsUpdatingModel(true);fetch(\"\".concat(endPoint,\"/v1/models/\"),{method:'GET'}).then(function(response){return response.json();}).then(function(data){var newLlmData=[];var newEmbeddingModelData=[];var newImageModelData=[];var newRerankModelData=[];Object.entries(data).forEach(function(_ref){var _ref2=_slicedToArray(_ref,2),key=_ref2[0],value=_ref2[1];var newValue=_objectSpread(_objectSpread({},value),{},{id:key,url:key});if(newValue.model_type==='LLM'){newLlmData.push(newValue);}else if(newValue.model_type==='embedding'){newEmbeddingModelData.push(newValue);}else if(newValue.model_type==='image'){newImageModelData.push(newValue);}else if(newValue.model_type==='rerank'){newRerankModelData.push(newValue);}});setLlmData(newLlmData);setEmbeddingModelData(newEmbeddingModelData);setImageModelData(newImageModelData);setRerankModelData(newRerankModelData);setIsUpdatingModel(false);}).catch(function(error){console.error('Error:',error);setIsUpdatingModel(false);});}};useEffect(function(){update(isCallingApi);// eslint-disable-next-line\n},[isCallingApi]);var llmColumns=[{field:'id',headerName:'ID',flex:1,minWidth:250},{field:'model_name',headerName:'Name',flex:1},{field:'address',headerName:'Address',flex:1},{field:'accelerators',headerName:'GPU Indexes',flex:1},{field:'model_size_in_billions',headerName:'Size',flex:1},{field:'quantization',headerName:'Quantization',flex:1},{field:'url',headerName:'Actions',flex:1,minWidth:200,sortable:false,filterable:false,disableColumnMenu:true,renderCell:function renderCell(_ref3){var row=_ref3.row;var url=row.url;var openUrl=\"\".concat(endPoint,\"/\")+url;var closeUrl=\"\".concat(endPoint,\"/v1/models/\")+url;var gradioUrl=\"\".concat(endPoint,\"/v1/ui/\")+url;if(url==='IS_LOADING'){return/*#__PURE__*/_jsx(\"div\",{});}return/*#__PURE__*/_jsxs(Box,{style:{width:'100%',display:'flex',justifyContent:'left',alignItems:'left'},children:[/*#__PURE__*/_jsx(\"button\",{title:\"Launch Web UI\",style:{borderWidth:'0px',backgroundColor:'transparent',paddingLeft:'0px',paddingRight:'10px'},onClick:function onClick(){if(isCallingApi||isUpdatingModel){// Make sure no ongoing call\nreturn;}setIsCallingApi(true);fetch(openUrl,{method:'HEAD'}).then(function(response){if(response.status===404){// If web UI doesn't exist (404 Not Found)\nconsole.log('UI does not exist, creating new...');return fetch(gradioUrl,{method:'POST',headers:{'Content-Type':'application/json'},body:JSON.stringify({model_type:row.model_type,model_name:row.model_name,model_size_in_billions:row.model_size_in_billions,model_format:row.model_format,quantization:row.quantization,context_length:row.context_length,model_ability:row.model_ability,model_description:row.model_description,model_lang:row.model_lang})}).then(function(response){return response.json();}).then(function(){return window.open(openUrl,'_blank','noopener noreferrer');}).finally(function(){return setIsCallingApi(false);});}else if(response.ok){// If web UI does exist\nconsole.log('UI exists, opening...');window.open(openUrl,'_blank','noopener noreferrer');setIsCallingApi(false);}else{// Other HTTP errors\nconsole.error(\"Unexpected response status: \".concat(response.status));setIsCallingApi(false);}}).catch(function(error){console.error('Error:',error);setIsCallingApi(false);});},children:/*#__PURE__*/_jsx(Box,{width:\"40px\",m:\"0 auto\",p:\"5px\",display:\"flex\",justifyContent:\"center\",borderRadius:\"4px\",style:{border:'1px solid #e5e7eb',borderWidth:'1px',borderColor:'#e5e7eb'},children:/*#__PURE__*/_jsx(OpenInBrowserOutlinedIcon,{})})}),/*#__PURE__*/_jsx(\"button\",{title:\"Terminate Model\",style:{borderWidth:'0px',backgroundColor:'transparent',paddingLeft:'0px',paddingRight:'10px'},onClick:function onClick(){if(isCallingApi||isUpdatingModel){return;}setIsCallingApi(true);fetch(closeUrl,{method:'DELETE'}).then(function(response){response.json();}).then(function(){setIsCallingApi(false);}).catch(function(error){console.error('Error:',error);setIsCallingApi(false);});},children:/*#__PURE__*/_jsx(Box,{width:\"40px\",m:\"0 auto\",p:\"5px\",display:\"flex\",justifyContent:\"center\",borderRadius:\"4px\",style:{border:'1px solid #e5e7eb',borderWidth:'1px',borderColor:'#e5e7eb'},children:/*#__PURE__*/_jsx(DeleteOutlineOutlinedIcon,{})})})]});}}];var embeddingModelColumns=[{field:'id',headerName:'ID',flex:1,minWidth:250},{field:'model_name',headerName:'Name',flex:1},{field:'address',headerName:'Address',flex:1},{field:'accelerators',headerName:'GPU Indexes',flex:1},{field:'url',headerName:'Actions',flex:1,minWidth:200,sortable:false,filterable:false,disableColumnMenu:true,renderCell:function renderCell(_ref4){var row=_ref4.row;var url=row.url;var closeUrl=\"\".concat(endPoint,\"/v1/models/\")+url;if(url==='IS_LOADING'){return/*#__PURE__*/_jsx(\"div\",{});}return/*#__PURE__*/_jsx(Box,{style:{width:'100%',display:'flex',justifyContent:'left',alignItems:'left'},children:/*#__PURE__*/_jsx(\"button\",{title:\"Terminate Model\",style:{borderWidth:'0px',backgroundColor:'transparent',paddingLeft:'0px',paddingRight:'10px'},onClick:function onClick(){if(isCallingApi||isUpdatingModel){return;}setIsCallingApi(true);fetch(closeUrl,{method:'DELETE'}).then(function(response){response.json();}).then(function(){setIsCallingApi(false);}).catch(function(error){console.error('Error:',error);setIsCallingApi(false);});},children:/*#__PURE__*/_jsx(Box,{width:\"40px\",m:\"0 auto\",p:\"5px\",display:\"flex\",justifyContent:\"center\",borderRadius:\"4px\",style:{border:'1px solid #e5e7eb',borderWidth:'1px',borderColor:'#e5e7eb'},children:/*#__PURE__*/_jsx(DeleteOutlineOutlinedIcon,{})})})});}}];var imageModelColumns=embeddingModelColumns;var rerankModelColumns=embeddingModelColumns;return/*#__PURE__*/_jsxs(Box,{m:\"20px\",children:[/*#__PURE__*/_jsx(Title,{title:\"Running Models\"}),/*#__PURE__*/_jsxs(TabContext,{value:tabValue,children:[/*#__PURE__*/_jsx(Box,{sx:{borderBottom:1,borderColor:'divider'},children:/*#__PURE__*/_jsxs(TabList,{value:tabValue,onChange:handleTabChange,\"aria-label\":\"tabs\",children:[/*#__PURE__*/_jsx(Tab,{label:\"Language Models\",value:\"1\"}),/*#__PURE__*/_jsx(Tab,{label:\"Embedding Models\",value:\"2\"}),/*#__PURE__*/_jsx(Tab,{label:\"Image models\",value:\"3\"}),/*#__PURE__*/_jsx(Tab,{label:\"Rerank models\",value:\"4\"})]})}),/*#__PURE__*/_jsx(TabPanel,{value:\"1\",sx:{padding:0},children:/*#__PURE__*/_jsx(Box,{m:\"40px 0 0 0\",height:\"30vh\",children:/*#__PURE__*/_jsx(DataGrid,{rows:llmData,columns:llmColumns,sx:{'& .MuiDataGrid-main':{width:'95% !important',overflow:'visible'},'& .MuiDataGrid-row':{background:'white',margin:'10px 0px'},'& .MuiDataGrid-cell':{borderBottom:'none'},'& .CustomWide-cell':{minWidth:'250px !important'},'& .MuiDataGrid-columnHeaders':{borderBottom:'none'},'& .MuiDataGrid-columnHeaderTitle':{fontWeight:'bold'},'& .MuiDataGrid-virtualScroller':{overflowX:'visible !important',overflow:'visible'},'& .MuiDataGrid-footerContainer':{borderTop:'none'},'border-width':'0px'},slots:{noRowsOverlay:function noRowsOverlay(){return/*#__PURE__*/_jsx(Stack,{height:\"100%\",alignItems:\"center\",justifyContent:\"center\",children:\"No Running Models\"});},noResultsOverlay:function noResultsOverlay(){return/*#__PURE__*/_jsx(Stack,{height:\"100%\",alignItems:\"center\",justifyContent:\"center\",children:\"No Running Models Matches\"});}}})})}),/*#__PURE__*/_jsx(TabPanel,{value:\"2\",sx:{padding:0},children:/*#__PURE__*/_jsx(Box,{m:\"40px 0 0 0\",height:\"30vh\",children:/*#__PURE__*/_jsx(DataGrid,{rows:embeddingModelData,columns:embeddingModelColumns,sx:{'& .MuiDataGrid-main':{width:'95% !important',overflow:'visible'},'& .MuiDataGrid-row':{background:'white',margin:'10px 0px'},'& .MuiDataGrid-cell':{borderBottom:'none'},'& .CustomWide-cell':{minWidth:'250px !important'},'& .MuiDataGrid-columnHeaders':{borderBottom:'none'},'& .MuiDataGrid-columnHeaderTitle':{fontWeight:'bold'},'& .MuiDataGrid-virtualScroller':{overflowX:'visible !important',overflow:'visible'},'& .MuiDataGrid-footerContainer':{borderTop:'none'},'border-width':'0px'},slots:{noRowsOverlay:function noRowsOverlay(){return/*#__PURE__*/_jsx(Stack,{height:\"100%\",alignItems:\"center\",justifyContent:\"center\",children:\"No Running Models\"});},noResultsOverlay:function noResultsOverlay(){return/*#__PURE__*/_jsx(Stack,{height:\"100%\",alignItems:\"center\",justifyContent:\"center\",children:\"No Running Models Matches\"});}}})})}),/*#__PURE__*/_jsx(TabPanel,{value:\"3\",sx:{padding:0},children:/*#__PURE__*/_jsx(Box,{m:\"40px 0 0 0\",height:\"30vh\",children:/*#__PURE__*/_jsx(DataGrid,{rows:imageModelData,columns:imageModelColumns,sx:{'& .MuiDataGrid-main':{width:'95% !important',overflow:'visible'},'& .MuiDataGrid-row':{background:'white',margin:'10px 0px'},'& .MuiDataGrid-cell':{borderBottom:'none'},'& .CustomWide-cell':{minWidth:'250px !important'},'& .MuiDataGrid-columnHeaders':{borderBottom:'none'},'& .MuiDataGrid-columnHeaderTitle':{fontWeight:'bold'},'& .MuiDataGrid-virtualScroller':{overflowX:'visible !important',overflow:'visible'},'& .MuiDataGrid-footerContainer':{borderTop:'none'},'border-width':'0px'},slots:{noRowsOverlay:function noRowsOverlay(){return/*#__PURE__*/_jsx(Stack,{height:\"100%\",alignItems:\"center\",justifyContent:\"center\",children:\"No Running Models\"});},noResultsOverlay:function noResultsOverlay(){return/*#__PURE__*/_jsx(Stack,{height:\"100%\",alignItems:\"center\",justifyContent:\"center\",children:\"No Running Models Matches\"});}}})})}),/*#__PURE__*/_jsx(TabPanel,{value:\"4\",sx:{padding:0},children:/*#__PURE__*/_jsx(Box,{m:\"40px 0 0 0\",height:\"30vh\",children:/*#__PURE__*/_jsx(DataGrid,{rows:rerankModelData,columns:rerankModelColumns,sx:{'& .MuiDataGrid-main':{width:'95% !important',overflow:'visible'},'& .MuiDataGrid-row':{background:'white',margin:'10px 0px'},'& .MuiDataGrid-cell':{borderBottom:'none'},'& .CustomWide-cell':{minWidth:'250px !important'},'& .MuiDataGrid-columnHeaders':{borderBottom:'none'},'& .MuiDataGrid-columnHeaderTitle':{fontWeight:'bold'},'& .MuiDataGrid-virtualScroller':{overflowX:'visible !important',overflow:'visible'},'& .MuiDataGrid-footerContainer':{borderTop:'none'},'border-width':'0px'},slots:{noRowsOverlay:function noRowsOverlay(){return/*#__PURE__*/_jsx(Stack,{height:\"100%\",alignItems:\"center\",justifyContent:\"center\",children:\"No Running Models\"});},noResultsOverlay:function noResultsOverlay(){return/*#__PURE__*/_jsx(Stack,{height:\"100%\",alignItems:\"center\",justifyContent:\"center\",children:\"No Running Models Matches\"});}}})})})]})]});};export default RunningModels;","map":{"version":3,"names":["DeleteOutlineOutlinedIcon","OpenInBrowserOutlinedIcon","TabContext","TabList","TabPanel","Box","Stack","Tab","DataGrid","React","useContext","useEffect","useState","ApiContext","Title","jsx","_jsx","jsxs","_jsxs","RunningModels","_React$useState","_React$useState2","_slicedToArray","tabValue","setTabValue","_useState","_useState2","llmData","setLlmData","_useState3","_useState4","embeddingModelData","setEmbeddingModelData","_useState5","_useState6","imageModelData","setImageModelData","_useState7","_useState8","rerankModelData","setRerankModelData","_useContext","isCallingApi","setIsCallingApi","_useContext2","isUpdatingModel","setIsUpdatingModel","endPoint","handleTabChange","event","newValue","update","id","url","fetch","concat","method","then","response","json","data","newLlmData","newEmbeddingModelData","newImageModelData","newRerankModelData","Object","entries","forEach","_ref","_ref2","key","value","_objectSpread","model_type","push","catch","error","console","llmColumns","field","headerName","flex","minWidth","sortable","filterable","disableColumnMenu","renderCell","_ref3","row","openUrl","closeUrl","gradioUrl","style","width","display","justifyContent","alignItems","children","title","borderWidth","backgroundColor","paddingLeft","paddingRight","onClick","status","log","headers","body","JSON","stringify","model_name","model_size_in_billions","model_format","quantization","context_length","model_ability","model_description","model_lang","window","open","finally","ok","m","p","borderRadius","border","borderColor","embeddingModelColumns","_ref4","imageModelColumns","rerankModelColumns","sx","borderBottom","onChange","label","padding","height","rows","columns","overflow","background","margin","fontWeight","overflowX","borderTop","slots","noRowsOverlay","noResultsOverlay"],"sources":["/home/runner/work/inference/inference/xinference/web/ui/src/scenes/running_models/index.js"],"sourcesContent":["import DeleteOutlineOutlinedIcon from '@mui/icons-material/DeleteOutlineOutlined'\nimport OpenInBrowserOutlinedIcon from '@mui/icons-material/OpenInBrowserOutlined'\nimport { TabContext, TabList, TabPanel } from '@mui/lab'\nimport { Box, Stack, Tab } from '@mui/material'\nimport { DataGrid } from '@mui/x-data-grid'\nimport React, { useContext, useEffect, useState } from 'react'\n\nimport { ApiContext } from '../../components/apiContext'\nimport Title from '../../components/Title'\n\nconst RunningModels = () => {\n const [tabValue, setTabValue] = React.useState('1')\n const [llmData, setLlmData] = useState([])\n const [embeddingModelData, setEmbeddingModelData] = useState([])\n const [imageModelData, setImageModelData] = useState([])\n const [rerankModelData, setRerankModelData] = useState([])\n const { isCallingApi, setIsCallingApi } = useContext(ApiContext)\n const { isUpdatingModel, setIsUpdatingModel } = useContext(ApiContext)\n const endPoint = useContext(ApiContext).endPoint\n\n const handleTabChange = (event, newValue) => {\n setTabValue(newValue)\n }\n\n const update = (isCallingApi) => {\n if (isCallingApi) {\n setLlmData([{ id: 'Loading, do not refresh page...', url: 'IS_LOADING' }])\n setEmbeddingModelData([\n { id: 'Loading, do not refresh page...', url: 'IS_LOADING' },\n ])\n setImageModelData([\n { id: 'Loading, do not refresh page...', url: 'IS_LOADING' },\n ])\n setRerankModelData([\n { id: 'Loading, do not refresh page...', url: 'IS_LOADING' },\n ])\n } else {\n setIsUpdatingModel(true)\n fetch(`${endPoint}/v1/models/`, {\n method: 'GET',\n })\n .then((response) => response.json())\n .then((data) => {\n const newLlmData = []\n const newEmbeddingModelData = []\n const newImageModelData = []\n const newRerankModelData = []\n Object.entries(data).forEach(([key, value]) => {\n let newValue = {\n ...value,\n id: key,\n url: key,\n }\n if (newValue.model_type === 'LLM') {\n newLlmData.push(newValue)\n } else if (newValue.model_type === 'embedding') {\n newEmbeddingModelData.push(newValue)\n } else if (newValue.model_type === 'image') {\n newImageModelData.push(newValue)\n } else if (newValue.model_type === 'rerank') {\n newRerankModelData.push(newValue)\n }\n })\n setLlmData(newLlmData)\n setEmbeddingModelData(newEmbeddingModelData)\n setImageModelData(newImageModelData)\n setRerankModelData(newRerankModelData)\n setIsUpdatingModel(false)\n })\n .catch((error) => {\n console.error('Error:', error)\n setIsUpdatingModel(false)\n })\n }\n }\n\n useEffect(() => {\n update(isCallingApi)\n // eslint-disable-next-line\n }, [isCallingApi])\n\n const llmColumns = [\n {\n field: 'id',\n headerName: 'ID',\n flex: 1,\n minWidth: 250,\n },\n {\n field: 'model_name',\n headerName: 'Name',\n flex: 1,\n },\n {\n field: 'address',\n headerName: 'Address',\n flex: 1,\n },\n {\n field: 'accelerators',\n headerName: 'GPU Indexes',\n flex: 1,\n },\n {\n field: 'model_size_in_billions',\n headerName: 'Size',\n flex: 1,\n },\n {\n field: 'quantization',\n headerName: 'Quantization',\n flex: 1,\n },\n {\n field: 'url',\n headerName: 'Actions',\n flex: 1,\n minWidth: 200,\n sortable: false,\n filterable: false,\n disableColumnMenu: true,\n renderCell: ({ row }) => {\n const url = row.url\n const openUrl = `${endPoint}/` + url\n const closeUrl = `${endPoint}/v1/models/` + url\n const gradioUrl = `${endPoint}/v1/ui/` + url\n\n if (url === 'IS_LOADING') {\n return <div></div>\n }\n\n return (\n <Box\n style={{\n width: '100%',\n display: 'flex',\n justifyContent: 'left',\n alignItems: 'left',\n }}\n >\n <button\n title=\"Launch Web UI\"\n style={{\n borderWidth: '0px',\n backgroundColor: 'transparent',\n paddingLeft: '0px',\n paddingRight: '10px',\n }}\n onClick={() => {\n if (isCallingApi || isUpdatingModel) {\n // Make sure no ongoing call\n return\n }\n\n setIsCallingApi(true)\n\n fetch(openUrl, {\n method: 'HEAD',\n })\n .then((response) => {\n if (response.status === 404) {\n // If web UI doesn't exist (404 Not Found)\n console.log('UI does not exist, creating new...')\n return fetch(gradioUrl, {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/json',\n },\n body: JSON.stringify({\n model_type: row.model_type,\n model_name: row.model_name,\n model_size_in_billions: row.model_size_in_billions,\n model_format: row.model_format,\n quantization: row.quantization,\n context_length: row.context_length,\n model_ability: row.model_ability,\n model_description: row.model_description,\n model_lang: row.model_lang,\n }),\n })\n .then((response) => response.json())\n .then(() =>\n window.open(openUrl, '_blank', 'noopener noreferrer')\n )\n .finally(() => setIsCallingApi(false))\n } else if (response.ok) {\n // If web UI does exist\n console.log('UI exists, opening...')\n window.open(openUrl, '_blank', 'noopener noreferrer')\n setIsCallingApi(false)\n } else {\n // Other HTTP errors\n console.error(\n `Unexpected response status: ${response.status}`\n )\n setIsCallingApi(false)\n }\n })\n .catch((error) => {\n console.error('Error:', error)\n setIsCallingApi(false)\n })\n }}\n >\n <Box\n width=\"40px\"\n m=\"0 auto\"\n p=\"5px\"\n display=\"flex\"\n justifyContent=\"center\"\n borderRadius=\"4px\"\n style={{\n border: '1px solid #e5e7eb',\n borderWidth: '1px',\n borderColor: '#e5e7eb',\n }}\n >\n <OpenInBrowserOutlinedIcon />\n </Box>\n </button>\n <button\n title=\"Terminate Model\"\n style={{\n borderWidth: '0px',\n backgroundColor: 'transparent',\n paddingLeft: '0px',\n paddingRight: '10px',\n }}\n onClick={() => {\n if (isCallingApi || isUpdatingModel) {\n return\n }\n setIsCallingApi(true)\n fetch(closeUrl, {\n method: 'DELETE',\n })\n .then((response) => {\n response.json()\n })\n .then(() => {\n setIsCallingApi(false)\n })\n .catch((error) => {\n console.error('Error:', error)\n setIsCallingApi(false)\n })\n }}\n >\n <Box\n width=\"40px\"\n m=\"0 auto\"\n p=\"5px\"\n display=\"flex\"\n justifyContent=\"center\"\n borderRadius=\"4px\"\n style={{\n border: '1px solid #e5e7eb',\n borderWidth: '1px',\n borderColor: '#e5e7eb',\n }}\n >\n <DeleteOutlineOutlinedIcon />\n </Box>\n </button>\n </Box>\n )\n },\n },\n ]\n\n const embeddingModelColumns = [\n {\n field: 'id',\n headerName: 'ID',\n flex: 1,\n minWidth: 250,\n },\n {\n field: 'model_name',\n headerName: 'Name',\n flex: 1,\n },\n {\n field: 'address',\n headerName: 'Address',\n flex: 1,\n },\n {\n field: 'accelerators',\n headerName: 'GPU Indexes',\n flex: 1,\n },\n {\n field: 'url',\n headerName: 'Actions',\n flex: 1,\n minWidth: 200,\n sortable: false,\n filterable: false,\n disableColumnMenu: true,\n renderCell: ({ row }) => {\n const url = row.url\n const closeUrl = `${endPoint}/v1/models/` + url\n\n if (url === 'IS_LOADING') {\n return <div></div>\n }\n\n return (\n <Box\n style={{\n width: '100%',\n display: 'flex',\n justifyContent: 'left',\n alignItems: 'left',\n }}\n >\n <button\n title=\"Terminate Model\"\n style={{\n borderWidth: '0px',\n backgroundColor: 'transparent',\n paddingLeft: '0px',\n paddingRight: '10px',\n }}\n onClick={() => {\n if (isCallingApi || isUpdatingModel) {\n return\n }\n setIsCallingApi(true)\n fetch(closeUrl, {\n method: 'DELETE',\n })\n .then((response) => {\n response.json()\n })\n .then(() => {\n setIsCallingApi(false)\n })\n .catch((error) => {\n console.error('Error:', error)\n setIsCallingApi(false)\n })\n }}\n >\n <Box\n width=\"40px\"\n m=\"0 auto\"\n p=\"5px\"\n display=\"flex\"\n justifyContent=\"center\"\n borderRadius=\"4px\"\n style={{\n border: '1px solid #e5e7eb',\n borderWidth: '1px',\n borderColor: '#e5e7eb',\n }}\n >\n <DeleteOutlineOutlinedIcon />\n </Box>\n </button>\n </Box>\n )\n },\n },\n ]\n\n const imageModelColumns = embeddingModelColumns\n const rerankModelColumns = embeddingModelColumns\n\n return (\n <Box m=\"20px\">\n <Title title=\"Running Models\" />\n <TabContext value={tabValue}>\n <Box sx={{ borderBottom: 1, borderColor: 'divider' }}>\n <TabList\n value={tabValue}\n onChange={handleTabChange}\n aria-label=\"tabs\"\n >\n <Tab label=\"Language Models\" value=\"1\" />\n <Tab label=\"Embedding Models\" value=\"2\" />\n <Tab label=\"Image models\" value=\"3\" />\n <Tab label=\"Rerank models\" value=\"4\" />\n </TabList>\n </Box>\n <TabPanel value=\"1\" sx={{ padding: 0 }}>\n <Box m=\"40px 0 0 0\" height=\"30vh\">\n <DataGrid\n rows={llmData}\n columns={llmColumns}\n sx={{\n '& .MuiDataGrid-main': {\n width: '95% !important',\n overflow: 'visible',\n },\n '& .MuiDataGrid-row': {\n background: 'white',\n margin: '10px 0px',\n },\n '& .MuiDataGrid-cell': {\n borderBottom: 'none',\n },\n '& .CustomWide-cell': {\n minWidth: '250px !important',\n },\n '& .MuiDataGrid-columnHeaders': {\n borderBottom: 'none',\n },\n '& .MuiDataGrid-columnHeaderTitle': {\n fontWeight: 'bold',\n },\n '& .MuiDataGrid-virtualScroller': {\n overflowX: 'visible !important',\n overflow: 'visible',\n },\n '& .MuiDataGrid-footerContainer': {\n borderTop: 'none',\n },\n 'border-width': '0px',\n }}\n slots={{\n noRowsOverlay: () => (\n <Stack\n height=\"100%\"\n alignItems=\"center\"\n justifyContent=\"center\"\n >\n No Running Models\n </Stack>\n ),\n noResultsOverlay: () => (\n <Stack\n height=\"100%\"\n alignItems=\"center\"\n justifyContent=\"center\"\n >\n No Running Models Matches\n </Stack>\n ),\n }}\n />\n </Box>\n </TabPanel>\n <TabPanel value=\"2\" sx={{ padding: 0 }}>\n <Box m=\"40px 0 0 0\" height=\"30vh\">\n <DataGrid\n rows={embeddingModelData}\n columns={embeddingModelColumns}\n sx={{\n '& .MuiDataGrid-main': {\n width: '95% !important',\n overflow: 'visible',\n },\n '& .MuiDataGrid-row': {\n background: 'white',\n margin: '10px 0px',\n },\n '& .MuiDataGrid-cell': {\n borderBottom: 'none',\n },\n '& .CustomWide-cell': {\n minWidth: '250px !important',\n },\n '& .MuiDataGrid-columnHeaders': {\n borderBottom: 'none',\n },\n '& .MuiDataGrid-columnHeaderTitle': {\n fontWeight: 'bold',\n },\n '& .MuiDataGrid-virtualScroller': {\n overflowX: 'visible !important',\n overflow: 'visible',\n },\n '& .MuiDataGrid-footerContainer': {\n borderTop: 'none',\n },\n 'border-width': '0px',\n }}\n slots={{\n noRowsOverlay: () => (\n <Stack\n height=\"100%\"\n alignItems=\"center\"\n justifyContent=\"center\"\n >\n No Running Models\n </Stack>\n ),\n noResultsOverlay: () => (\n <Stack\n height=\"100%\"\n alignItems=\"center\"\n justifyContent=\"center\"\n >\n No Running Models Matches\n </Stack>\n ),\n }}\n />\n </Box>\n </TabPanel>\n <TabPanel value=\"3\" sx={{ padding: 0 }}>\n <Box m=\"40px 0 0 0\" height=\"30vh\">\n <DataGrid\n rows={imageModelData}\n columns={imageModelColumns}\n sx={{\n '& .MuiDataGrid-main': {\n width: '95% !important',\n overflow: 'visible',\n },\n '& .MuiDataGrid-row': {\n background: 'white',\n margin: '10px 0px',\n },\n '& .MuiDataGrid-cell': {\n borderBottom: 'none',\n },\n '& .CustomWide-cell': {\n minWidth: '250px !important',\n },\n '& .MuiDataGrid-columnHeaders': {\n borderBottom: 'none',\n },\n '& .MuiDataGrid-columnHeaderTitle': {\n fontWeight: 'bold',\n },\n '& .MuiDataGrid-virtualScroller': {\n overflowX: 'visible !important',\n overflow: 'visible',\n },\n '& .MuiDataGrid-footerContainer': {\n borderTop: 'none',\n },\n 'border-width': '0px',\n }}\n slots={{\n noRowsOverlay: () => (\n <Stack\n height=\"100%\"\n alignItems=\"center\"\n justifyContent=\"center\"\n >\n No Running Models\n </Stack>\n ),\n noResultsOverlay: () => (\n <Stack\n height=\"100%\"\n alignItems=\"center\"\n justifyContent=\"center\"\n >\n No Running Models Matches\n </Stack>\n ),\n }}\n />\n </Box>\n </TabPanel>\n <TabPanel value=\"4\" sx={{ padding: 0 }}>\n <Box m=\"40px 0 0 0\" height=\"30vh\">\n <DataGrid\n rows={rerankModelData}\n columns={rerankModelColumns}\n sx={{\n '& .MuiDataGrid-main': {\n width: '95% !important',\n overflow: 'visible',\n },\n '& .MuiDataGrid-row': {\n background: 'white',\n margin: '10px 0px',\n },\n '& .MuiDataGrid-cell': {\n borderBottom: 'none',\n },\n '& .CustomWide-cell': {\n minWidth: '250px !important',\n },\n '& .MuiDataGrid-columnHeaders': {\n borderBottom: 'none',\n },\n '& .MuiDataGrid-columnHeaderTitle': {\n fontWeight: 'bold',\n },\n '& .MuiDataGrid-virtualScroller': {\n overflowX: 'visible !important',\n overflow: 'visible',\n },\n '& .MuiDataGrid-footerContainer': {\n borderTop: 'none',\n },\n 'border-width': '0px',\n }}\n slots={{\n noRowsOverlay: () => (\n <Stack\n height=\"100%\"\n alignItems=\"center\"\n justifyContent=\"center\"\n >\n No Running Models\n </Stack>\n ),\n noResultsOverlay: () => (\n <Stack\n height=\"100%\"\n alignItems=\"center\"\n justifyContent=\"center\"\n >\n No Running Models Matches\n </Stack>\n ),\n }}\n />\n </Box>\n </TabPanel>\n </TabContext>\n </Box>\n )\n}\n\nexport default RunningModels\n"],"mappings":"yRAAA,MAAO,CAAAA,yBAAyB,KAAM,2CAA2C,CACjF,MAAO,CAAAC,yBAAyB,KAAM,2CAA2C,CACjF,OAASC,UAAU,CAAEC,OAAO,CAAEC,QAAQ,KAAQ,UAAU,CACxD,OAASC,GAAG,CAAEC,KAAK,CAAEC,GAAG,KAAQ,eAAe,CAC/C,OAASC,QAAQ,KAAQ,kBAAkB,CAC3C,MAAO,CAAAC,KAAK,EAAIC,UAAU,CAAEC,SAAS,CAAEC,QAAQ,KAAQ,OAAO,CAE9D,OA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CAAE,CACLC,aAAa,CAAE,SAAAA,cAAA,qBACblI,IAAA,CAACV,KAAK,EACJkI,MAAM,CAAC,MAAM,CACbxC,UAAU,CAAC,QAAQ,CACnBD,cAAc,CAAC,QAAQ,CAAAE,QAAA,CACxB,mBAED,CAAO,CAAC,EACT,CACDkD,gBAAgB,CAAE,SAAAA,iBAAA,qBAChBnI,IAAA,CAACV,KAAK,EACJkI,MAAM,CAAC,MAAM,CACbxC,UAAU,CAAC,QAAQ,CACnBD,cAAc,CAAC,QAAQ,CAAAE,QAAA,CACxB,2BAED,CAAO,CAAC,EAEZ,CAAE,CACH,CAAC,CACC,CAAC,CACE,CAAC,EACD,CAAC,EACV,CAAC,CAEV,CAAC,CAED,cAAe,CAAA9E,aAAa"},"metadata":{},"sourceType":"module","externalDependencies":[]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"ast":null,"code":"import _regeneratorRuntime from\"/home/runner/work/inference/inference/xinference/web/ui/node_modules/@babel/runtime/helpers/esm/regeneratorRuntime.js\";import _asyncToGenerator from\"/home/runner/work/inference/inference/xinference/web/ui/node_modules/@babel/runtime/helpers/esm/asyncToGenerator.js\";import _slicedToArray from\"/home/runner/work/inference/inference/xinference/web/ui/node_modules/@babel/runtime/helpers/esm/slicedToArray.js\";import{Box,FormControl,InputLabel,MenuItem,Select,TextField}from'@mui/material';import React,{useContext,useEffect,useState}from'react';import{ApiContext}from'../../components/apiContext';import ModelCard from'./modelCard';import{jsx as _jsx}from\"react/jsx-runtime\";import{jsxs as _jsxs}from\"react/jsx-runtime\";var LaunchLLM=function LaunchLLM(){var endPoint=useContext(ApiContext).endPoint;var _useState=useState([]),_useState2=_slicedToArray(_useState,2),registrationData=_useState2[0],setRegistrationData=_useState2[1];var _useContext=useContext(ApiContext),isCallingApi=_useContext.isCallingApi,setIsCallingApi=_useContext.setIsCallingApi;var _useContext2=useContext(ApiContext),isUpdatingModel=_useContext2.isUpdatingModel;var _useContext3=useContext(ApiContext),setErrorMsg=_useContext3.setErrorMsg;// States used for filtering\nvar _useState3=useState(''),_useState4=_slicedToArray(_useState3,2),searchTerm=_useState4[0],setSearchTerm=_useState4[1];var _useState5=useState('all'),_useState6=_slicedToArray(_useState5,2),modelAbility=_useState6[0],setModelAbility=_useState6[1];var _useState7=useState(-1),_useState8=_slicedToArray(_useState7,2),gpuAvailable=_useState8[0],setGPUAvailable=_useState8[1];var handleChange=function handleChange(event){setSearchTerm(event.target.value);};var handleAbilityChange=function handleAbilityChange(event){setModelAbility(event.target.value);};var filter=function filter(registration){if(!registration||typeof searchTerm!=='string')return false;var modelName=registration.model_name?registration.model_name.toLowerCase():'';var modelDescription=registration.model_description?registration.model_description.toLowerCase():'';if(!modelName.includes(searchTerm.toLowerCase())&&!modelDescription.includes(searchTerm.toLowerCase())){return false;}if(modelAbility&&modelAbility!=='all'){if(registration.model_ability.indexOf(modelAbility)<0){return false;}}return true;};var update=/*#__PURE__*/function(){var _ref=_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(){var response,registrations,builtinRegistrations;return _regeneratorRuntime().wrap(function _callee$(_context){while(1)switch(_context.prev=_context.next){case 0:if(!(isCallingApi||isUpdatingModel)){_context.next=2;break;}return _context.abrupt(\"return\");case 2:_context.prev=2;setIsCallingApi(true);_context.next=6;return fetch(\"\".concat(endPoint,\"/v1/model_registrations/LLM?detailed=true\"),{method:'GET'});case 6:response=_context.sent;_context.next=9;return response.json();case 9:registrations=_context.sent;builtinRegistrations=registrations.filter(function(v){return v.is_builtin;});setRegistrationData(builtinRegistrations);_context.next=17;break;case 14:_context.prev=14;_context.t0=_context[\"catch\"](2);console.error('Error:',_context.t0);case 17:_context.prev=17;setIsCallingApi(false);return _context.finish(17);case 20:case\"end\":return _context.stop();}},_callee,null,[[2,14,17,20]]);}));return function update(){return _ref.apply(this,arguments);};}();useEffect(function(){update();},[]);useEffect(function(){if(gpuAvailable===-1){fetch(endPoint+'/v1/cluster/devices',{method:'GET',headers:{'Content-Type':'application/json'}}).then(function(res){if(!res.ok){// Usually, if some errors happen here, check if the cluster is available\nres.json().then(function(errorData){setErrorMsg(\"Server error: \".concat(res.status,\" - \").concat(errorData.detail||'Unknown error'));});}else{res.json().then(function(data){setGPUAvailable(parseInt(data,10));});}});}},[]);var style={display:'grid',gridTemplateColumns:'repeat(auto-fill, minmax(300px, 1fr))',paddingLeft:'2rem',gridGap:'2rem 0rem'};return/*#__PURE__*/_jsxs(Box,{m:\"20px\",children:[/*#__PURE__*/_jsxs(\"div\",{style:{display:'grid',gridTemplateColumns:'150px 1fr',columnGap:'20px',margin:'30px 2rem'},children:[/*#__PURE__*/_jsxs(FormControl,{variant:\"outlined\",margin:\"normal\",children:[/*#__PURE__*/_jsx(InputLabel,{id:\"ability-select-label\",children:\"Model Ability\"}),/*#__PURE__*/_jsxs(Select,{id:\"ability\",labelId:\"ability-select-label\",label:\"Model Ability\",onChange:handleAbilityChange,value:modelAbility,size:\"small\",sx:{width:'150px'},children:[/*#__PURE__*/_jsx(MenuItem,{value:\"all\",children:\"all\"}),/*#__PURE__*/_jsx(MenuItem,{value:\"generate\",children:\"generate\"}),/*#__PURE__*/_jsx(MenuItem,{value:\"chat\",children:\"chat\"})]})]}),/*#__PURE__*/_jsx(FormControl,{variant:\"outlined\",margin:\"normal\",children:/*#__PURE__*/_jsx(TextField,{id:\"search\",type:\"search\",label:\"Search for model name and description\",value:searchTerm,onChange:handleChange,size:\"small\"})})]}),/*#__PURE__*/_jsx(\"div\",{style:style,children:registrationData.filter(function(registration){return filter(registration);}).map(function(filteredRegistration){return/*#__PURE__*/_jsx(ModelCard,{url:endPoint,modelData:filteredRegistration,gpuAvailable:gpuAvailable});})})]});};export default LaunchLLM;","map":{"version":3,"names":["Box","FormControl","InputLabel","MenuItem","Select","TextField","React","useContext","useEffect","useState","ApiContext","ModelCard","jsx","_jsx","jsxs","_jsxs","LaunchLLM","endPoint","_useState","_useState2","_slicedToArray","registrationData","setRegistrationData","_useContext","isCallingApi","setIsCallingApi","_useContext2","isUpdatingModel","_useContext3","setErrorMsg","_useState3","_useState4","searchTerm","setSearchTerm","_useState5","_useState6","modelAbility","setModelAbility","_useState7","_useState8","gpuAvailable","setGPUAvailable","handleChange","event","target","value","handleAbilityChange","filter","registration","modelName","model_name","toLowerCase","modelDescription","model_description","includes","model_ability","indexOf","update","_ref","_asyncToGenerator","_regeneratorRuntime","mark","_callee","response","registrations","builtinRegistrations","wrap","_callee$","_context","prev","next","abrupt","fetch","concat","method","sent","json","v","is_builtin","t0","console","error","finish","stop","apply","arguments","headers","then","res","ok","errorData","status","detail","data","parseInt","style","display","gridTemplateColumns","paddingLeft","gridGap","m","children","columnGap","margin","variant","id","labelId","label","onChange","size","sx","width","type","map","filteredRegistration","url","modelData"],"sources":["/home/runner/work/inference/inference/xinference/web/ui/src/scenes/launch_model/launchLLM.js"],"sourcesContent":["import {\n Box,\n FormControl,\n InputLabel,\n MenuItem,\n Select,\n TextField,\n} from '@mui/material'\nimport React, { useContext, useEffect, useState } from 'react'\n\nimport { ApiContext } from '../../components/apiContext'\nimport ModelCard from './modelCard'\n\nconst LaunchLLM = () => {\n let endPoint = useContext(ApiContext).endPoint\n const [registrationData, setRegistrationData] = useState([])\n const { isCallingApi, setIsCallingApi } = useContext(ApiContext)\n const { isUpdatingModel } = useContext(ApiContext)\n const { setErrorMsg } = useContext(ApiContext)\n\n // States used for filtering\n const [searchTerm, setSearchTerm] = useState('')\n\n const [modelAbility, setModelAbility] = useState('all')\n const [gpuAvailable, setGPUAvailable] = useState(-1)\n\n const handleChange = (event) => {\n setSearchTerm(event.target.value)\n }\n\n const handleAbilityChange = (event) => {\n setModelAbility(event.target.value)\n }\n\n const filter = (registration) => {\n if (!registration || typeof searchTerm !== 'string') return false\n const modelName = registration.model_name\n ? registration.model_name.toLowerCase()\n : ''\n const modelDescription = registration.model_description\n ? registration.model_description.toLowerCase()\n : ''\n\n if (\n !modelName.includes(searchTerm.toLowerCase()) &&\n !modelDescription.includes(searchTerm.toLowerCase())\n ) {\n return false\n }\n if (modelAbility && modelAbility !== 'all') {\n if (registration.model_ability.indexOf(modelAbility) < 0) {\n return false\n }\n }\n return true\n }\n\n const update = async () => {\n if (isCallingApi || isUpdatingModel) return\n\n try {\n setIsCallingApi(true)\n\n const response = await fetch(\n `${endPoint}/v1/model_registrations/LLM?detailed=true`,\n {\n method: 'GET',\n }\n )\n\n const registrations = await response.json()\n const builtinRegistrations = registrations.filter((v) => v.is_builtin)\n\n setRegistrationData(builtinRegistrations)\n } catch (error) {\n console.error('Error:', error)\n } finally {\n setIsCallingApi(false)\n }\n }\n\n useEffect(() => {\n update()\n }, [])\n\n useEffect(() => {\n if (gpuAvailable === -1) {\n fetch(endPoint + '/v1/cluster/devices', {\n method: 'GET',\n headers: {\n 'Content-Type': 'application/json',\n },\n }).then((res) => {\n if (!res.ok) {\n // Usually, if some errors happen here, check if the cluster is available\n res.json().then((errorData) => {\n setErrorMsg(\n `Server error: ${res.status} - ${\n errorData.detail || 'Unknown error'\n }`\n )\n })\n } else {\n res.json().then((data) => {\n setGPUAvailable(parseInt(data, 10))\n })\n }\n })\n }\n }, [])\n\n const style = {\n display: 'grid',\n gridTemplateColumns: 'repeat(auto-fill, minmax(300px, 1fr))',\n paddingLeft: '2rem',\n gridGap: '2rem 0rem',\n }\n\n return (\n <Box m=\"20px\">\n <div\n style={{\n display: 'grid',\n gridTemplateColumns: '150px 1fr',\n columnGap: '20px',\n margin: '30px 2rem',\n }}\n >\n <FormControl variant=\"outlined\" margin=\"normal\">\n <InputLabel id=\"ability-select-label\">Model Ability</InputLabel>\n <Select\n id=\"ability\"\n labelId=\"ability-select-label\"\n label=\"Model Ability\"\n onChange={handleAbilityChange}\n value={modelAbility}\n size=\"small\"\n sx={{ width: '150px' }}\n >\n <MenuItem value=\"all\">all</MenuItem>\n <MenuItem value=\"generate\">generate</MenuItem>\n <MenuItem value=\"chat\">chat</MenuItem>\n </Select>\n </FormControl>\n <FormControl variant=\"outlined\" margin=\"normal\">\n <TextField\n id=\"search\"\n type=\"search\"\n label=\"Search for model name and description\"\n value={searchTerm}\n onChange={handleChange}\n size=\"small\"\n />\n </FormControl>\n </div>\n <div style={style}>\n {registrationData\n .filter((registration) => filter(registration))\n .map((filteredRegistration) => (\n <ModelCard\n url={endPoint}\n modelData={filteredRegistration}\n gpuAvailable={gpuAvailable}\n />\n ))}\n </div>\n </Box>\n )\n}\n\nexport default LaunchLLM\n"],"mappings":"ubAAA,OACEA,GAAG,CACHC,WAAW,CACXC,UAAU,CACVC,QAAQ,CACRC,MAAM,CACNC,SAAS,KACJ,eAAe,CACtB,MAAO,CAAAC,KAAK,EAAIC,UAAU,CAAEC,SAAS,CAAEC,QAAQ,KAAQ,OAAO,CAE9D,OAASC,UAAU,KAAQ,6BAA6B,CACxD,MAAO,CAAAC,SAAS,KAAM,aAAa,QAAAC,GAAA,IAAAC,IAAA,gCAAAC,IAAA,IAAAC,KAAA,yBAEnC,GAAM,CAAAC,SAAS,CAAG,QAAZ,CAAAA,SAASA,CAAA,CAAS,CACtB,GAAI,CAAAC,QAAQ,CAAGV,UAAU,CAACG,UAAU,CAAC,CAACO,QAAQ,CAC9C,IAAAC,SAAA,CAAgDT,QAAQ,CAAC,EAAE,CAAC,CAAAU,UAAA,CAAAC,cAAA,CAAAF,SAAA,IAArDG,gBAAgB,CAAAF,UAAA,IAAEG,mBAAmB,CAAAH,UAAA,IAC5C,IAAAI,WAAA,CAA0ChB,UAAU,CAACG,UAAU,CAAC,CAAxDc,YAAY,CAAAD,WAAA,CAAZC,YAAY,CAAEC,eAAe,CAAAF,WAAA,CAAfE,eAAe,CACrC,IAAAC,YAAA,CAA4BnB,UAAU,CAACG,UAAU,CAAC,CAA1CiB,eAAe,CAAAD,YAAA,CAAfC,eAAe,CACvB,IAAAC,YAAA,CAAwBrB,UAAU,CAACG,UAAU,CAAC,CAAtCmB,WAAW,CAAAD,YAAA,CAAXC,WAAW,CAEnB;AACA,IAAAC,UAAA,CAAoCrB,QAAQ,CAAC,EAAE,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,MAAM,CAAC,SAACC,YAAY,QAAK,CAAAD,MAAM,CAACC,YAAY,CAAC,GAAC,CAC9CiE,GAAG,CAAC,SAACC,oBAAoB,qBACxBrG,IAAA,CAACF,SAAS,EACRwG,GAAG,CAAElG,QAAS,CACdmG,SAAS,CAAEF,oBAAqB,CAChC1E,YAAY,CAAEA,YAAa,CAC5B,CAAC,EACH,CAAC,CACD,CAAC,EACH,CAAC,CAEV,CAAC,CAED,cAAe,CAAAxB,SAAS"},"metadata":{},"sourceType":"module","externalDependencies":[]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"ast":null,"code":"import _objectSpread from\"/home/runner/work/inference/inference/xinference/web/ui/node_modules/@babel/runtime/helpers/esm/objectSpread2.js\";import _slicedToArray from\"/home/runner/work/inference/inference/xinference/web/ui/node_modules/@babel/runtime/helpers/esm/slicedToArray.js\";import{RocketLaunchOutlined,UndoOutlined}from'@mui/icons-material';import DeleteIcon from'@mui/icons-material/Delete';import{Box,Chip,CircularProgress,Stack}from'@mui/material';import IconButton from'@mui/material/IconButton';import React,{useContext,useEffect,useState}from'react';import{v1 as uuidv1}from'uuid';import{ApiContext}from'../../components/apiContext';import{jsx as _jsx}from\"react/jsx-runtime\";import{jsxs as _jsxs}from\"react/jsx-runtime\";var CARD_HEIGHT=270;var CARD_WIDTH=270;var EmbeddingCard=function EmbeddingCard(_ref){var url=_ref.url,modelData=_ref.modelData,_ref$cardHeight=_ref.cardHeight,cardHeight=_ref$cardHeight===void 0?CARD_HEIGHT:_ref$cardHeight,_ref$is_custom=_ref.is_custom,is_custom=_ref$is_custom===void 0?false:_ref$is_custom;var _useState=useState(false),_useState2=_slicedToArray(_useState,2),hover=_useState2[0],setHover=_useState2[1];var _useState3=useState(false),_useState4=_slicedToArray(_useState3,2),selected=_useState4[0],setSelected=_useState4[1];var _useState5=useState(false),_useState6=_slicedToArray(_useState5,2),customDeleted=_useState6[0],setCustomDeleted=_useState6[1];var _useContext=useContext(ApiContext),isCallingApi=_useContext.isCallingApi,setIsCallingApi=_useContext.setIsCallingApi;var _useContext2=useContext(ApiContext),isUpdatingModel=_useContext2.isUpdatingModel;var _useContext3=useContext(ApiContext),setErrorMsg=_useContext3.setErrorMsg;// UseEffects for parameter selection, change options based on previous selections\nuseEffect(function(){},[modelData]);var launchModel=function launchModel(url){if(isCallingApi||isUpdatingModel){return;}setIsCallingApi(true);var uuid=uuidv1();var modelDataWithID={model_uid:uuid,model_name:modelData.model_name,model_type:'embedding'};// First fetch request to initiate the model\nfetch(url+'/v1/models',{method:'POST',headers:{'Content-Type':'application/json'},body:JSON.stringify(modelDataWithID)}).then(function(res){if(!res.ok){res.json().then(function(errData){return setErrorMsg(\"Server error: \".concat(res.status,\" - \").concat(errData.detail||'Unknown error'));});}else{window.open(url+'/ui/#/running_models','_blank','noreferrer');}setIsCallingApi(false);}).catch(function(error){console.error('Error:',error);setIsCallingApi(false);});};var styles={container:{display:'block',position:'relative',width:\"\".concat(CARD_WIDTH,\"px\"),height:\"\".concat(cardHeight,\"px\"),border:'1px solid #ddd',borderRadius:'20px',background:'white',overflow:'hidden'},containerSelected:{display:'block',position:'relative',width:\"\".concat(CARD_WIDTH,\"px\"),height:\"\".concat(cardHeight,\"px\"),border:'1px solid #ddd',borderRadius:'20px',background:'white',overflow:'hidden',boxShadow:'0 0 2px #00000099'},descriptionCard:{position:'relative',top:'-1px',left:'-1px',width:\"\".concat(CARD_WIDTH,\"px\"),height:\"\".concat(cardHeight,\"px\"),border:'1px solid #ddd',padding:'20px',borderRadius:'20px',background:'white'},parameterCard:{position:'relative',top:\"-\".concat(cardHeight+1,\"px\"),left:'-1px',width:\"\".concat(CARD_WIDTH,\"px\"),height:\"\".concat(cardHeight,\"px\"),border:'1px solid #ddd',padding:'20px',borderRadius:'20px',background:'white'},img:{display:'block',margin:'0 auto',width:'180px',height:'180px',objectFit:'cover',borderRadius:'10px'},titleContainer:{minHeight:'120px'},h2:{margin:'10px 10px',fontSize:'20px'},buttonsContainer:{display:'flex',margin:'0 auto',marginTop:'120px',border:'none',justifyContent:'space-between',alignItems:'center'},buttonContainer:{width:'45%',borderWidth:'0px',backgroundColor:'transparent',paddingLeft:'0px',paddingRight:'0px'},buttonItem:{width:'100%',margin:'0 auto',padding:'5px',display:'flex',justifyContent:'center',borderRadius:'4px',border:'1px solid #e5e7eb',borderWidth:'1px',borderColor:'#e5e7eb'},instructionText:{fontSize:'12px',color:'#666666',fontStyle:'italic',margin:'10px 0',textAlign:'center'},slideIn:{transform:'translateX(0%)',transition:'transform 0.2s ease-in-out'},slideOut:{transform:'translateX(100%)',transition:'transform 0.2s ease-in-out'},iconRow:{display:'flex',justifyContent:'space-between',alignItems:'center'},iconItem:{display:'flex',flexDirection:'column',alignItems:'center',margin:'20px'},boldIconText:{fontWeight:'bold',fontSize:'1.2em'},muiIcon:{fontSize:'1.5em'},smallText:{fontSize:'0.8em'},langRow:{margin:'2px 5px 40px 5px'}};var handeCustomDelete=function handeCustomDelete(e){e.stopPropagation();fetch(url+\"/v1/model_registrations/embedding/\".concat(modelData.model_name),{method:'DELETE',headers:{'Content-Type':'application/json'}}).then(function(){return setCustomDeleted(true);}).catch(console.error);};// Set two different states based on mouse hover\nreturn/*#__PURE__*/_jsxs(Box,{style:hover?styles.containerSelected:styles.container,onMouseEnter:function onMouseEnter(){return setHover(true);},onMouseLeave:function onMouseLeave(){return setHover(false);},onClick:function onClick(){if(!selected&&!customDeleted){setSelected(true);}},children:[/*#__PURE__*/_jsxs(Box,{style:styles.descriptionCard,children:[/*#__PURE__*/_jsxs(\"div\",{style:styles.titleContainer,children:[is_custom&&/*#__PURE__*/_jsxs(Stack,{direction:\"row\",justifyContent:\"space-evenly\",alignItems:\"center\",spacing:1,children:[/*#__PURE__*/_jsx(\"h2\",{style:styles.h2,children:modelData.model_name}),/*#__PURE__*/_jsx(IconButton,{\"aria-label\":\"delete\",onClick:handeCustomDelete,disabled:customDeleted,children:/*#__PURE__*/_jsx(DeleteIcon,{})})]}),!is_custom&&/*#__PURE__*/_jsx(\"h2\",{style:styles.h2,children:modelData.model_name}),/*#__PURE__*/_jsxs(\"div\",{style:styles.langRow,children:[function(){if(modelData.language.includes('en')){return/*#__PURE__*/_jsx(Chip,{label:\"EN\",variant:\"outlined\",size:\"small\",sx:{marginRight:'10px'}});}}(),function(){if(modelData.language.includes('zh')){return/*#__PURE__*/_jsx(Chip,{label:\"ZH\",variant:\"outlined\",size:\"small\"});}}(),function(){if(is_custom&&customDeleted){return/*#__PURE__*/_jsx(Chip,{label:\"Deleted\",variant:\"outlined\",size:\"small\",sx:{marginLeft:'10px'}});}}()]})]}),/*#__PURE__*/_jsxs(\"div\",{style:styles.iconRow,children:[/*#__PURE__*/_jsxs(\"div\",{style:styles.iconItem,children:[/*#__PURE__*/_jsx(\"span\",{style:styles.boldIconText,children:modelData.dimensions}),/*#__PURE__*/_jsx(\"small\",{style:styles.smallText,children:\"dimensions\"})]}),/*#__PURE__*/_jsxs(\"div\",{style:styles.iconItem,children:[/*#__PURE__*/_jsx(\"span\",{style:styles.boldIconText,children:modelData.max_tokens}),/*#__PURE__*/_jsx(\"small\",{style:styles.smallText,children:\"max tokens\"})]})]}),hover?/*#__PURE__*/_jsx(\"p\",{style:styles.instructionText,children:\"Click with mouse to launch the model\"}):/*#__PURE__*/_jsx(\"p\",{style:styles.instructionText})]}),/*#__PURE__*/_jsxs(Box,{style:selected?_objectSpread(_objectSpread({},styles.parameterCard),styles.slideIn):_objectSpread(_objectSpread({},styles.parameterCard),styles.slideOut),children:[/*#__PURE__*/_jsx(\"h2\",{style:styles.h2,children:modelData.model_name}),/*#__PURE__*/_jsxs(Box,{style:styles.buttonsContainer,children:[/*#__PURE__*/_jsx(\"button\",{title:\"Launch Embedding\",style:styles.buttonContainer,onClick:function onClick(){return launchModel(url,modelData);},disabled:isCallingApi||isUpdatingModel||!modelData,children:function(){if(isCallingApi||isUpdatingModel){return/*#__PURE__*/_jsx(Box,{style:_objectSpread(_objectSpread({},styles.buttonItem),{},{backgroundColor:'#f2f2f2'}),children:/*#__PURE__*/_jsx(CircularProgress,{size:\"20px\",sx:{color:'#000000'}})});}else if(!modelData){return/*#__PURE__*/_jsx(Box,{style:_objectSpread(_objectSpread({},styles.buttonItem),{},{backgroundColor:'#f2f2f2'}),children:/*#__PURE__*/_jsx(RocketLaunchOutlined,{size:\"20px\"})});}else{return/*#__PURE__*/_jsx(Box,{style:styles.buttonItem,children:/*#__PURE__*/_jsx(RocketLaunchOutlined,{color:\"#000000\",size:\"20px\"})});}}()}),/*#__PURE__*/_jsx(\"button\",{title:\"Launch Embedding\",style:styles.buttonContainer,onClick:function onClick(){return setSelected(false);},children:/*#__PURE__*/_jsx(Box,{style:styles.buttonItem,children:/*#__PURE__*/_jsx(UndoOutlined,{color:\"#000000\",size:\"20px\"})})})]})]})]});};export default EmbeddingCard;","map":{"version":3,"names":["RocketLaunchOutlined","UndoOutlined","DeleteIcon","Box","Chip","CircularProgress","Stack","IconButton","React","useContext","useEffect","useState","v1","uuidv1","ApiContext","jsx","_jsx","jsxs","_jsxs","CARD_HEIGHT","CARD_WIDTH","EmbeddingCard","_ref","url","modelData","_ref$cardHeight","cardHeight","_ref$is_custom","is_custom","_useState","_useState2","_slicedToArray","hover","setHover","_useState3","_useState4","selected","setSelected","_useState5","_useState6","customDeleted","setCustomDeleted","_useContext","isCallingApi","setIsCallingApi","_useContext2","isUpdatingModel","_useContext3","setErrorMsg","launchModel","uuid","modelDataWithID","model_uid","model_name","model_type","fetch","method","headers","body","JSON","stringify","then","res","ok","json","errData","concat","status","detail","window","open","catch","error","console","styles","container","display","position","width","height","border","borderRadius","background","overflow","containerSelected","boxShadow","descriptionCard","top","left","padding","parameterCard","img","margin","objectFit","titleContainer","minHeight","h2","fontSize","buttonsContainer","marginTop","justifyContent","alignItems","buttonContainer","borderWidth","backgroundColor","paddingLeft","paddingRight","buttonItem","borderColor","instructionText","color","fontStyle","textAlign","slideIn","transform","transition","slideOut","iconRow","iconItem","flexDirection","boldIconText","fontWeight","muiIcon","smallText","langRow","handeCustomDelete","e","stopPropagation","style","onMouseEnter","onMouseLeave","onClick","children","direction","spacing","disabled","language","includes","label","variant","size","sx","marginRight","marginLeft","dimensions","max_tokens","_objectSpread","title"],"sources":["/home/runner/work/inference/inference/xinference/web/ui/src/scenes/launch_model/embeddingCard.js"],"sourcesContent":["import { RocketLaunchOutlined, UndoOutlined } from '@mui/icons-material'\nimport DeleteIcon from '@mui/icons-material/Delete'\nimport { Box, Chip, CircularProgress, Stack } from '@mui/material'\nimport IconButton from '@mui/material/IconButton'\nimport React, { useContext, useEffect, useState } from 'react'\nimport { v1 as uuidv1 } from 'uuid'\n\nimport { ApiContext } from '../../components/apiContext'\n\nconst CARD_HEIGHT = 270\nconst CARD_WIDTH = 270\n\nconst EmbeddingCard = ({\n url,\n modelData,\n cardHeight = CARD_HEIGHT,\n is_custom = false,\n}) => {\n const [hover, setHover] = useState(false)\n const [selected, setSelected] = useState(false)\n const [customDeleted, setCustomDeleted] = useState(false)\n const { isCallingApi, setIsCallingApi } = useContext(ApiContext)\n const { isUpdatingModel } = useContext(ApiContext)\n const { setErrorMsg } = useContext(ApiContext)\n\n // UseEffects for parameter selection, change options based on previous selections\n useEffect(() => {}, [modelData])\n\n const launchModel = (url) => {\n if (isCallingApi || isUpdatingModel) {\n return\n }\n\n setIsCallingApi(true)\n\n const uuid = uuidv1()\n const modelDataWithID = {\n model_uid: uuid,\n model_name: modelData.model_name,\n model_type: 'embedding',\n }\n\n // First fetch request to initiate the model\n fetch(url + '/v1/models', {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/json',\n },\n body: JSON.stringify(modelDataWithID),\n })\n .then((res) => {\n if (!res.ok) {\n res\n .json()\n .then((errData) =>\n setErrorMsg(\n `Server error: ${res.status} - ${\n errData.detail || 'Unknown error'\n }`\n )\n )\n } else {\n window.open(url + '/ui/#/running_models', '_blank', 'noreferrer')\n }\n setIsCallingApi(false)\n })\n .catch((error) => {\n console.error('Error:', error)\n setIsCallingApi(false)\n })\n }\n\n const styles = {\n container: {\n display: 'block',\n position: 'relative',\n width: `${CARD_WIDTH}px`,\n height: `${cardHeight}px`,\n border: '1px solid #ddd',\n borderRadius: '20px',\n background: 'white',\n overflow: 'hidden',\n },\n containerSelected: {\n display: 'block',\n position: 'relative',\n width: `${CARD_WIDTH}px`,\n height: `${cardHeight}px`,\n border: '1px solid #ddd',\n borderRadius: '20px',\n background: 'white',\n overflow: 'hidden',\n boxShadow: '0 0 2px #00000099',\n },\n descriptionCard: {\n position: 'relative',\n top: '-1px',\n left: '-1px',\n width: `${CARD_WIDTH}px`,\n height: `${cardHeight}px`,\n border: '1px solid #ddd',\n padding: '20px',\n borderRadius: '20px',\n background: 'white',\n },\n parameterCard: {\n position: 'relative',\n top: `-${cardHeight + 1}px`,\n left: '-1px',\n width: `${CARD_WIDTH}px`,\n height: `${cardHeight}px`,\n border: '1px solid #ddd',\n padding: '20px',\n borderRadius: '20px',\n background: 'white',\n },\n img: {\n display: 'block',\n margin: '0 auto',\n width: '180px',\n height: '180px',\n objectFit: 'cover',\n borderRadius: '10px',\n },\n titleContainer: {\n minHeight: '120px',\n },\n h2: {\n margin: '10px 10px',\n fontSize: '20px',\n },\n buttonsContainer: {\n display: 'flex',\n margin: '0 auto',\n marginTop: '120px',\n border: 'none',\n justifyContent: 'space-between',\n alignItems: 'center',\n },\n buttonContainer: {\n width: '45%',\n borderWidth: '0px',\n backgroundColor: 'transparent',\n paddingLeft: '0px',\n paddingRight: '0px',\n },\n buttonItem: {\n width: '100%',\n margin: '0 auto',\n padding: '5px',\n display: 'flex',\n justifyContent: 'center',\n borderRadius: '4px',\n border: '1px solid #e5e7eb',\n borderWidth: '1px',\n borderColor: '#e5e7eb',\n },\n instructionText: {\n fontSize: '12px',\n color: '#666666',\n fontStyle: 'italic',\n margin: '10px 0',\n textAlign: 'center',\n },\n slideIn: {\n transform: 'translateX(0%)',\n transition: 'transform 0.2s ease-in-out',\n },\n slideOut: {\n transform: 'translateX(100%)',\n transition: 'transform 0.2s ease-in-out',\n },\n iconRow: {\n display: 'flex',\n justifyContent: 'space-between',\n alignItems: 'center',\n },\n iconItem: {\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n margin: '20px',\n },\n boldIconText: {\n fontWeight: 'bold',\n fontSize: '1.2em',\n },\n muiIcon: {\n fontSize: '1.5em',\n },\n smallText: {\n fontSize: '0.8em',\n },\n langRow: {\n margin: '2px 5px 40px 5px',\n },\n }\n\n const handeCustomDelete = (e) => {\n e.stopPropagation()\n fetch(url + `/v1/model_registrations/embedding/${modelData.model_name}`, {\n method: 'DELETE',\n headers: {\n 'Content-Type': 'application/json',\n },\n })\n .then(() => setCustomDeleted(true))\n .catch(console.error)\n }\n\n // Set two different states based on mouse hover\n return (\n <Box\n style={hover ? styles.containerSelected : styles.container}\n onMouseEnter={() => setHover(true)}\n onMouseLeave={() => setHover(false)}\n onClick={() => {\n if (!selected && !customDeleted) {\n setSelected(true)\n }\n }}\n >\n {/* First state: show description page */}\n <Box style={styles.descriptionCard}>\n <div style={styles.titleContainer}>\n {is_custom && (\n <Stack\n direction=\"row\"\n justifyContent=\"space-evenly\"\n alignItems=\"center\"\n spacing={1}\n >\n <h2 style={styles.h2}>{modelData.model_name}</h2>\n <IconButton\n aria-label=\"delete\"\n onClick={handeCustomDelete}\n disabled={customDeleted}\n >\n <DeleteIcon />\n </IconButton>\n </Stack>\n )}\n {!is_custom && <h2 style={styles.h2}>{modelData.model_name}</h2>}\n <div style={styles.langRow}>\n {(() => {\n if (modelData.language.includes('en')) {\n return (\n <Chip\n label=\"EN\"\n variant=\"outlined\"\n size=\"small\"\n sx={{ marginRight: '10px' }}\n />\n )\n }\n })()}\n {(() => {\n if (modelData.language.includes('zh')) {\n return <Chip label=\"ZH\" variant=\"outlined\" size=\"small\" />\n }\n })()}\n {(() => {\n if (is_custom && customDeleted) {\n return (\n <Chip\n label=\"Deleted\"\n variant=\"outlined\"\n size=\"small\"\n sx={{ marginLeft: '10px' }}\n />\n )\n }\n })()}\n </div>\n </div>\n <div style={styles.iconRow}>\n <div style={styles.iconItem}>\n <span style={styles.boldIconText}>{modelData.dimensions}</span>\n <small style={styles.smallText}>dimensions</small>\n </div>\n <div style={styles.iconItem}>\n <span style={styles.boldIconText}>{modelData.max_tokens}</span>\n <small style={styles.smallText}>max tokens</small>\n </div>\n </div>\n {hover ? (\n <p style={styles.instructionText}>\n Click with mouse to launch the model\n </p>\n ) : (\n <p style={styles.instructionText}></p>\n )}\n </Box>\n {/* Second state: show parameter selection page */}\n <Box\n style={\n selected\n ? { ...styles.parameterCard, ...styles.slideIn }\n : { ...styles.parameterCard, ...styles.slideOut }\n }\n >\n <h2 style={styles.h2}>{modelData.model_name}</h2>\n <Box style={styles.buttonsContainer}>\n <button\n title=\"Launch Embedding\"\n style={styles.buttonContainer}\n onClick={() => launchModel(url, modelData)}\n disabled={isCallingApi || isUpdatingModel || !modelData}\n >\n {(() => {\n if (isCallingApi || isUpdatingModel) {\n return (\n <Box\n style={{ ...styles.buttonItem, backgroundColor: '#f2f2f2' }}\n >\n <CircularProgress\n size=\"20px\"\n sx={{\n color: '#000000',\n }}\n />\n </Box>\n )\n } else if (!modelData) {\n return (\n <Box\n style={{ ...styles.buttonItem, backgroundColor: '#f2f2f2' }}\n >\n <RocketLaunchOutlined size=\"20px\" />\n </Box>\n )\n } else {\n return (\n <Box style={styles.buttonItem}>\n <RocketLaunchOutlined color=\"#000000\" size=\"20px\" />\n </Box>\n )\n }\n })()}\n </button>\n <button\n title=\"Launch Embedding\"\n style={styles.buttonContainer}\n onClick={() => setSelected(false)}\n >\n <Box style={styles.buttonItem}>\n <UndoOutlined color=\"#000000\" size=\"20px\" />\n </Box>\n </button>\n </Box>\n </Box>\n </Box>\n )\n}\n\nexport default EmbeddingCard\n"],"mappings":"yRAAA,OAASA,oBAAoB,CAAEC,YAAY,KAAQ,qBAAqB,CACxE,MAAO,CAAAC,UAAU,KAAM,4BAA4B,CACnD,OAASC,GAAG,CAAEC,IAAI,CAA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ACF/B,KAAK,CAAE,SACT,CAAE,CACH,CAAC,CACC,CAAC,CAEV,CAAC,IAAM,IAAI,CAACtF,SAAS,CAAE,CACrB,mBACER,IAAA,CAACb,GAAG,EACF6H,KAAK,CAAAkB,aAAA,CAAAA,aAAA,IAAOxE,MAAM,CAACiC,UAAU,MAAEH,eAAe,CAAE,SAAS,EAAG,CAAA4B,QAAA,cAE5DpH,IAAA,CAAChB,oBAAoB,EAAC4I,IAAI,CAAC,MAAM,CAAE,CAAC,CACjC,CAAC,CAEV,CAAC,IAAM,CACL,mBACE5H,IAAA,CAACb,GAAG,EAAC6H,KAAK,CAAEtD,MAAM,CAACiC,UAAW,CAAAyB,QAAA,cAC5BpH,IAAA,CAAChB,oBAAoB,EAAC8G,KAAK,CAAC,SAAS,CAAC8B,IAAI,CAAC,MAAM,CAAE,CAAC,CACjD,CAAC,CAEV,CACF,CAAC,CAAE,CAAC,CACE,CAAC,cACT5H,IAAA,WACEmI,KAAK,CAAC,kBAAkB,CACxBnB,KAAK,CAAEtD,MAAM,CAAC4B,eAAgB,CAC9B6B,OAAO,CAAE,SAAAA,QAAA,QAAM,CAAA9F,WAAW,CAAC,KAAK,CAAC,EAAC,CAAA+F,QAAA,cAElCpH,IAAA,CAACb,GAAG,EAAC6H,KAAK,CAAEtD,MAAM,CAACiC,UAAW,CAAAyB,QAAA,cAC5BpH,IAAA,CAACf,YAAY,EAAC6G,KAAK,CAAC,SAAS,CAAC8B,IAAI,CAAC,MAAM,CAAE,CAAC,CACzC,CAAC,CACA,CAAC,EACN,CAAC,EACH,CAAC,EACH,CAAC,CAEV,CAAC,CAED,cAAe,CAAAvH,aAAa"},"metadata":{},"sourceType":"module","externalDependencies":[]}
|
/xinference/web/ui/build/static/js/{main.8126d441.js.LICENSE.txt → main.778615cc.js.LICENSE.txt}
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|