utils

package
v0.0.0-...-a59c08c Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 24, 2025 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateTweetFragment

func CreateTweetFragment(tweet *twitter.ParsedTweet, actorId id.ID, embedding []float32) (*db.Fragment, error)

Helper method to create fragment from tweet

func DecodeTweetMetadata

func DecodeTweetMetadata(input interface{}, result *twitter.ParsedTweet) error

DecodeTweetMetadata is a helper function to decode tweet metadata using json tags

func SmartUnmarshal

func SmartUnmarshal(data []byte, v interface{}) error

SmartUnmarshal removes Markdown code fences from the input data (if present) and then unmarshals the remaining JSON into `v`.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL