|
|
@ -41,7 +41,7 @@ The `Artifact` class includes various methods for creating, editing, saving, loa
|
|
|
|
artifact = Artifact(file_path="example.txt", file_type="txt")
|
|
|
|
artifact = Artifact(file_path="example.txt", file_type="txt")
|
|
|
|
artifact.create(initial_content="Initial file content")
|
|
|
|
artifact.create(initial_content="Initial file content")
|
|
|
|
```
|
|
|
|
```
|
|
|
|
|
|
|
|
The file type parameter supports the following file types: `.txt`, `.md`, `.py`, `.pdf`.
|
|
|
|
#### `edit`
|
|
|
|
#### `edit`
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -240,4 +240,4 @@ new_artifact = Artifact.from_dict(artifact_dict)
|
|
|
|
|
|
|
|
|
|
|
|
# Print the metrics of the new artifact
|
|
|
|
# Print the metrics of the new artifact
|
|
|
|
print(new_artifact.get_metrics())
|
|
|
|
print(new_artifact.get_metrics())
|
|
|
|
```
|
|
|
|
```
|
|
|
|