Chisle
The coding-agent plugin that bills 52% of a bare model across 20 live tasks. Terse persona + tool-output compressor + context diet.
翻訳待ち
No updates detected yet. GitHub releases will appear here.
Web-based annotation library with rich controls, customization and serialization in mind
翻訳待ち
Loading the full README.
Read the full README ↗Web-based image annotation library with rich drawing controls, customizable annotation contexts, and built-in serialization.
Powered by OpenSeaDragon for deep zoom tiled image support and Fabric.js v7 for interactive canvas rendering, with official UI bindings for SolidJS and React. Draw rectangles, circles, lines, points, and freehand paths on gigapixel images with smooth pan and zoom.
DecorationProvider functions, recomputed at render time (never serialized)customControl overlay mode that routes raw pointer input to your own handler, used by the built-in two-axis exposure/contrast gesturenpm install @osdlabel/solid
npm install @osdlabel/react
import { render } from 'solid-js/web';
import { Annotator, createImageId, createAnnotationContextId } from '@osdlabel/solid';
import type { ImageSource, AnnotationContext } from '@osdlabel/solid';
const images: ImageSource[] = [
{
id: createImageId('slide-1'),
tileSource: 'https://example.com/slides/slide-1.dzi',
label: 'Slide 1',
},
];
const contexts: AnnotationContext[] = [
{
id: createAnnotationContextId('review'),
label: 'Review',
tools: [
{ type: 'rectangle', maxCount: 5, countScope: 'per-image' },
{ type: 'circle' },
{ type: 'point' },
],
},
];
function App() {
return (
<div style={{ width: '100vw', height: '100vh' }}>
<Annotator
images={images}
contexts={contexts}
showFilmstrip={true}
showGridControls={true}
showContextSwitcher={true}
onAnnotationsChange={(annotations) => console.log(annotations)}
/>
</div>
);
}
render(() => <App />, document.getElementById('app')!);
import { createRoot } from 'react-dom/client';
import { Annotator, createImageId, createAnnotationContextId } from '@osdlabel/react';
import type { ImageSource, AnnotationContext } from '@osdlabel/react';
// images and contexts defined the same way as above
function App() {
return (
<div style={{ width: '100vw', height: '100vh' }}>
<Annotator
images={images}
contexts={contexts}
showFilmstrip={true}
showGridControls={true}
showContextSwitcher={true}
onAnnotationsChange={(annotations) => console.log(annotations)}
/>
</div>
);
}
createRoot(document.getElementById('app')!).render(<App />);
The viewer registers the Fabric id custom property automatically when it
mounts, so there is no setup call to remember. initFabricModule() is still
exported and idempotent for advanced setups that build Fabric objects before any
viewer exists.
For more control, use the individual components and provider directly:
// SolidJS — the same names are exported from '@osdlabel/react'
import {
AnnotatorProvider,
useAnnotator,
Toolbar,
StatusBar,
GridView,
Filmstrip,
GridControls,
ContextSwitcher,
ViewControls,
serialize,
deserialize,
} from '@osdlabel/solid';
Wrap your UI in <AnnotatorProvider>, call useAnnotator() for access to state and actions, then compose Toolbar, GridView, Filmstrip, StatusBar, GridControls, ContextSwitcher, and ViewControls however you like.
Import everything from the single umbrella package you already depend on
(@osdlabel/solid, @osdlabel/react, or osdlabel). Types such as ImageId,
AnnotationId, and ImageSource physically live in lower-level subpackages, so
importing them from those paths only resolves when the subpackage is a direct
dependency of your app. The umbrella re-exports them all.
Reach for the granular packages only when building a custom UI layer, and add them as explicit dependencies:
import type { Annotation, Geometry } from '@osdlabel/annotation';
import type { ImageSource } from '@osdlabel/viewer-api';
import type { AnnotationContext } from '@osdlabel/annotation-context';
import { serialize, deserialize, applyAnnotationAction } from 'osdlabel';
This is the beginning of the README. Read the rest at the original. Read the full README ↗