This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "TextFile", | |
"version": "0.1", | |
"namespace": "http://onto-ns.com/meta", | |
"meta": "http://onto-ns.com/meta/0.3/EntitySchema", | |
"description": "Representation an experimental image.", | |
"dimensions": [], | |
"properties": [ | |
{ | |
"name": "data", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
identity: http://onto-ns.com/entity/v1/demo#a77e5e81-2107-45f9-9dde-1f559d961d0a | |
description: Demonstration | |
dimensions: | |
N: Number of items | |
properties: | |
lat: | |
type: float | |
shape: ["N"] | |
description: Latitude |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"""Generate and validate starting positions for Fischer Random Chess, | |
also known as Chess960. Fischer Random Chess is a variant of | |
traditional chess invented by the former World Chess Champion Bobby | |
Fischer. It was introduced to add variety to the game and reduce the | |
reliance on opening memorization by randomly shuffling the positions | |
of the back-row pieces (rooks, knights, bishops, queen, and king) | |
while adhering to certain rules to ensure the game remains balanced | |
and playable. | |
Fischer Random Chess follows these specific rules for setting up the |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from dataclasses import dataclass, field | |
from typing import Any, Dict, Protocol, runtime_checkable | |
from redis import Redis | |
@runtime_checkable | |
class ICacheBackend(Protocol): | |
""" | |
Defines an interface for cache backends. Any class that implements this protocol | |
must provide `set`, `get`, and `aclose` methods. This allows for flexibility in | |
the cache implementation, as different storage mechanisms can be used as long as |
OlderNewer