Skip to content

Commit

Permalink
Add splash images
Browse files Browse the repository at this point in the history
  • Loading branch information
LaylBongers committed Jun 11, 2024
1 parent 9e53218 commit a72e27f
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 2 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# Mini Model Daemon

![splash](data/splash.png)

Quickly run an OpenAI-compatible chat completions endpoint, using RWKV language models (such as EagleX).

## Getting Started
Expand Down
9 changes: 8 additions & 1 deletion crates/minmodmon-dashboard/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@ use minmodmon_agent::{agent_service, start_activate_model};
pub fn create_router() -> Result<Router, Error> {
let router = Router::new()
.get(handle)
.push(Router::with_path("load_model").post(handle_load_model));
.push(Router::with_path("load_model").post(handle_load_model))
.push(Router::with_path("splash-bg.png").get(handle_splash));

Ok(router)
}
Expand Down Expand Up @@ -98,3 +99,9 @@ async fn handle_load_model(

Ok(())
}

#[handler]
async fn handle_splash(req: &mut Request, res: &mut Response) -> Result<(), Error> {
res.send_file("./data/splash-bg.png", req.headers()).await;
Ok(())
}
2 changes: 1 addition & 1 deletion data/dashboard.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta charset="utf-8">
<title>Mini Model Daemon - Dashboard</title>
</head>
<body>
<body style="background: center no-repeat url('splash-bg.png');">

<h1>Mini Model Daemon Dashboard</h1>

Expand Down
Binary file added data/splash-bg.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added data/splash.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit a72e27f

Please sign in to comment.