Commands Cheat Sheet

Try DrDroid: AI Agent for Debugging

80+ monitoring tool integrations
Long term memory about your stack
Locally run Mac App available

Thankyou for your submission

We have sent the cheatsheet on your email!
Oops! Something went wrong while submitting the form.

Thank you for your submission

We have sent the cheatsheet on your email!
Oops! Something went wrong while submitting the form.
Read more
Time to stop copy pasting your errors onto Google!

Connection

Connect to Weaviate instance using Python client
import weaviate; client = weaviate.Client('http://localhost:8080')

Connect with API key
client = weaviate.Client('http://localhost:8080', auth_client_secret=weaviate.AuthApiKey(api_key='your-api-key'))

Check if Weaviate is ready
client.is_ready()

Schema Management

Create a schema class
client.schema.create_class({ 'class': 'Article', 'properties': [{ 'name': 'title', 'dataType': ['text'] }] })

Get schema
client.schema.get()

Delete a class
client.schema.delete_class('Article')

Data Operations

Add data object
client.data_object.create({ 'title': 'Example Article' }, 'Article')

Get data object by id
client.data_object.get_by_id('uuid', 'Article')

Update data object
client.data_object.update({ 'title': 'Updated Article' }, 'Article', 'uuid')

Delete data object
client.data_object.delete('uuid', 'Article')

Vector Search

Perform vector search
client.query.get('Article', ['title']).with_near_text({ 'concepts': ['search term'] }).do()

Search with limit
client.query.get('Article', ['title']).with_near_text({ 'concepts': ['search term'] }).with_limit(10).do()

Search with distance
client.query.get('Article', ['title']).with_near_vector({ 'vector': [0.1, 0.2, ...] }).with_additional('distance').do()

Batch Operations

Create batch
client.batch.configure(batch_size=100)

Add to batch
client.batch.add_data_object({ 'title': 'Batch Article' }, 'Article')

Create batch with vectors
client.batch.add_data_object({ 'title': 'Vector Article' }, 'Article', vector=[0.1, 0.2, ...])

Flush batch
client.batch.flush()

GraphQL Queries

Raw GraphQL query
client.query.raw('{Get{Article{title}}}')

Hybrid search
client.query.get('Article', ['title']).with_hybrid({ 'query': 'search term', 'alpha': 0.5 }).do()