AI prompts
base on π π¦ The one-person framework for Rust for side-projects and startups <div align="center">
<img src="https://github.com/loco-rs/loco/assets/83390/992d215a-3cd3-42ee-a1c7-de9fd25a5bac"/>
<h1>Welcome to Loco</h1>
<h3>
<!-- <snip id="description" inject_from="yaml"> -->
π Loco is Rust on Rails.
<!--</snip> -->
</h3>
[![crate](https://img.shields.io/crates/v/loco-rs.svg)](https://crates.io/crates/loco-rs)
[![docs](https://docs.rs/loco-rs/badge.svg)](https://docs.rs/loco-rs)
[![Discord channel](https://img.shields.io/badge/discord-Join-us)](https://discord.gg/fTvyBzwKS8)
</div>
English Β· [δΈζ](./README-zh_CN.md) Β· [FranΓ§ais](./README.fr.md) Β· [Portuguese (Brazil)](./README-pt_BR.md) γ» [ζ₯ζ¬θͺ](./README.ja.md) Β· [νκ΅μ΄](./README.ko.md) Β· [Π ΡΡΡΠΊΠΈΠΉ](./README.ru.md)
## What's Loco?
`Loco` is strongly inspired by Rails. If you know Rails and Rust, you'll feel at home. If you only know Rails and new to Rust, you'll find Loco refreshing. We do not assume you know Rails.
For a deeper dive into how Loco works, including detailed guides, examples, and API references, check out our [documentation website](https://loco.rs).
## Features of Loco:
* `Convention Over Configuration:` Similar to Ruby on Rails, Loco emphasizes simplicity and productivity by reducing the need for boilerplate code. It uses sensible defaults, allowing developers to focus on writing business logic rather than spending time on configuration.
* `Rapid Development:` Aim for high developer productivity, Locoβs design focuses on reducing boilerplate code and providing intuitive APIs, allowing developers to iterate quickly and build prototypes with minimal effort.
* `ORM Integration:` Model your business with robust entities, eliminating the need to write SQL. Define relationships, validation, and custom logic directly on your entities for enhanced maintainability and scalability.
* `Controllers`: Handle web requests parameters, body, validation, and render a response that is content-aware. We use Axum for the best performance, simplicity, and extensibility. Controllers also allow you to easily build middlewares, which can be used to add logic such as authentication, logging, or error handling before passing requests to the main controller actions.
* `Views:` Loco can integrate with templating engines to generate dynamic HTML content from templates.
* `Background Jobs:` Perform compute or I/O intensive jobs in the background with a Redis backed queue, or with threads. Implementing a worker is as simple as implementing a perform function for the Worker trait.
* `Scheduler:` Simplifies the traditional, often cumbersome crontab system, making it easier and more elegant to schedule tasks or shell scripts.
* `Mailers:` A mailer will deliver emails in the background using the existing loco background worker infrastructure. It will all be seamless for you.
* `Storage:` In Loco Storage, we facilitate working with files through multiple operations. Storage can be in-memory, on disk, or use cloud services such as AWS S3, GCP, and Azure.
* `Cache:` Loco provides an cache layer to improve application performance by storing frequently accessed data.
So see more Loco features, check out our [documentation website](https://loco.rs/docs/getting-started/tour/).
## Getting Started
<!-- <snip id="quick-installation-command" inject_from="yaml" template="sh"> -->
```sh
cargo install loco
cargo install sea-orm-cli # Only when DB is needed
```
<!-- </snip> -->
Now you can create your new app (choose "`SaaS` app").
<!-- <snip id="loco-cli-new-from-template" inject_from="yaml" template="sh"> -->
```sh
β― loco new
β β― App name? Β· myapp
β β― What would you like to build? Β· Saas App with client side rendering
β β― Select a DB Provider Β· Sqlite
β β― Select your background worker type Β· Async (in-process tokio async tasks)
π Loco app generated successfully in:
myapp/
- assets: You've selected `clientside` for your asset serving configuration.
Next step, build your frontend:
$ cd frontend/
$ npm install && npm run build
```
<!-- </snip> -->
Now `cd` into your `myapp` and start your app:
<!-- <snip id="starting-the-server-command-with-output" inject_from="yaml" template="sh"> -->
```sh
$ cargo loco start
β β
β β
β β β β ββ
β βββ
β β β βββββ
βββ
βββββββ βββββββββ βββββββββββ βββββββββ βββ
ββββββ βββββ βββ βββββ βββ βββββ βββ ββ
ββββββ βββββ βββ βββββ βββ βββββ βββ βββ
ββββββ βββββ βββ βββββ βββββ βββ βββββ
ββββββ βββββ βββ βββββ βββ βββββ βββ βββββ
ββββββ βββββ βββ ββββ βββ βββββ βββ βββββ
ββββββ ββββββββββ ββββββββββ ββββββββββ βββ
βββββββββββββββββββββββββββββββββββββββ
https://loco.rs
listening on port 5150
```
<!-- </snip> -->
## Powered by Loco
+ [SpectralOps](https://spectralops.io) - various services powered by Loco
framework
+ [Nativish](https://nativi.sh) - app backend powered by Loco framework
## Contributors β¨
Thanks goes to these wonderful people:
<a href="https://github.com/loco-rs/loco/graphs/contributors">
<img src="https://contrib.rocks/image?repo=loco-rs/loco" />
</a>
", Assign "at most 3 tags" to the expected json: {"id":"5698","tags":[]} "only from the tags list I provide: [{"id":77,"name":"3d"},{"id":89,"name":"agent"},{"id":17,"name":"ai"},{"id":54,"name":"algorithm"},{"id":24,"name":"api"},{"id":44,"name":"authentication"},{"id":3,"name":"aws"},{"id":27,"name":"backend"},{"id":60,"name":"benchmark"},{"id":72,"name":"best-practices"},{"id":39,"name":"bitcoin"},{"id":37,"name":"blockchain"},{"id":1,"name":"blog"},{"id":45,"name":"bundler"},{"id":58,"name":"cache"},{"id":21,"name":"chat"},{"id":49,"name":"cicd"},{"id":4,"name":"cli"},{"id":64,"name":"cloud-native"},{"id":48,"name":"cms"},{"id":61,"name":"compiler"},{"id":68,"name":"containerization"},{"id":92,"name":"crm"},{"id":34,"name":"data"},{"id":47,"name":"database"},{"id":8,"name":"declarative-gui "},{"id":9,"name":"deploy-tool"},{"id":53,"name":"desktop-app"},{"id":6,"name":"dev-exp-lib"},{"id":59,"name":"dev-tool"},{"id":13,"name":"ecommerce"},{"id":26,"name":"editor"},{"id":66,"name":"emulator"},{"id":62,"name":"filesystem"},{"id":80,"name":"finance"},{"id":15,"name":"firmware"},{"id":73,"name":"for-fun"},{"id":2,"name":"framework"},{"id":11,"name":"frontend"},{"id":22,"name":"game"},{"id":81,"name":"game-engine "},{"id":23,"name":"graphql"},{"id":84,"name":"gui"},{"id":91,"name":"http"},{"id":5,"name":"http-client"},{"id":51,"name":"iac"},{"id":30,"name":"ide"},{"id":78,"name":"iot"},{"id":40,"name":"json"},{"id":83,"name":"julian"},{"id":38,"name":"k8s"},{"id":31,"name":"language"},{"id":10,"name":"learning-resource"},{"id":33,"name":"lib"},{"id":41,"name":"linter"},{"id":28,"name":"lms"},{"id":16,"name":"logging"},{"id":76,"name":"low-code"},{"id":90,"name":"message-queue"},{"id":42,"name":"mobile-app"},{"id":18,"name":"monitoring"},{"id":36,"name":"networking"},{"id":7,"name":"node-version"},{"id":55,"name":"nosql"},{"id":57,"name":"observability"},{"id":46,"name":"orm"},{"id":52,"name":"os"},{"id":14,"name":"parser"},{"id":74,"name":"react"},{"id":82,"name":"real-time"},{"id":56,"name":"robot"},{"id":65,"name":"runtime"},{"id":32,"name":"sdk"},{"id":71,"name":"search"},{"id":63,"name":"secrets"},{"id":25,"name":"security"},{"id":85,"name":"server"},{"id":86,"name":"serverless"},{"id":70,"name":"storage"},{"id":75,"name":"system-design"},{"id":79,"name":"terminal"},{"id":29,"name":"testing"},{"id":12,"name":"ui"},{"id":50,"name":"ux"},{"id":88,"name":"video"},{"id":20,"name":"web-app"},{"id":35,"name":"web-server"},{"id":43,"name":"webassembly"},{"id":69,"name":"workflow"},{"id":87,"name":"yaml"}]" returns me the "expected json"