mirror of
https://github.com/Significant-Gravitas/AutoGPT.git
synced 2026-02-12 15:55:03 -05:00
Restructuring the Repo to make it clear the difference between classic autogpt and the autogpt platform: * Move the "classic" projects `autogpt`, `forge`, `frontend`, and `benchmark` into a `classic` folder * Also rename `autogpt` to `original_autogpt` for absolute clarity * Rename `rnd/` to `autogpt_platform/` * `rnd/autogpt_builder` -> `autogpt_platform/frontend` * `rnd/autogpt_server` -> `autogpt_platform/backend` * Adjust any paths accordingly
18 lines
385 B
Python
18 lines
385 B
Python
import base64
|
|
import json
|
|
|
|
# Load JSON data from a file
|
|
with open("secrets.json", "r") as f:
|
|
data = json.load(f)
|
|
|
|
# Convert the JSON object into a string
|
|
json_string = json.dumps(data)
|
|
|
|
# Encode the string into bytes
|
|
json_bytes = json_string.encode("utf-8")
|
|
|
|
# Convert the bytes to a base64 string
|
|
base64_string = base64.b64encode(json_bytes).decode("utf-8")
|
|
|
|
print(base64_string)
|