kcaverly
/
deepseek-coder-6.7b-instruct
A ~7B parameter language model from Deepseek for SOTA repository level code completion
Prediction
kcaverly/deepseek-coder-6.7b-instruct:e86e32a176426ab0bcbc2beaeb94b90334777219815be3aef1e958def2c73c56IDfjugwu3b7gvoanx577qjyd6jfaStatusSucceededSourceWebHardwareA40 (Large)Total durationCreatedInput
- messages
- [{"role": "user", "content": "please create a rust enum named prediction status, with three variants starting, in progress and complete"}]
- do_sample
- max_new_tokens
- 512
- num_return_sequences
- 1
Output
Sure, here is how you can define an enum named `PredictionStatus` with three variants: `Starting`, `InProgress`, and `Complete` in Rust: ```rust #[derive(Debug)] enum PredictionStatus { Starting, InProgress, Complete, } ``` In this code: - `#[derive(Debug)]` is an attribute that tells Rust to derive certain traits for this enum. In this case, `Debug` is used to enable printing of the enum variants for debugging purposes. - `enum PredictionStatus` defines a new enum type named `PredictionStatus`. - `Starting`, `InProgress`, and `Complete` are the variants of the enum. You can use this enum in your code like this: ```rust fn main() { let status = PredictionStatus::Starting; println!("{:?}", status); // prints: Starting } ``` In this code, `PredictionStatus::Starting` creates a value of the `PredictionStatus` enum with the variant `Starting`. The `println!` macro with the `{:?}` format string is used to print the enum value, which will print the variant name.Generated in
Want to make some of these yourself?
Run this model