Giter Site home page Giter Site logo

omaus / nbformat.net Goto Github PK

View Code? Open in Web Editor NEW

This project forked from fslaborg/nbformat.net

0.0 0.0 0.0 46 KB

A pure F# library for parsing and converting the `.ipynb` notebook file format

License: MIT License

Shell 0.18% F# 85.44% Batchfile 0.12% Jupyter Notebook 14.26%

nbformat.net's Introduction

NBFormat.NET

A pure F# library for parsing the .ipynb notebook file format v4.

It uses System.Text.Json in conjunction with the absolutely amazing FSharp.SystemTextJson library.

There currently is a missing link in the .NET ecosystem between working in .NET notebooks and exporting them to other formats. If you want to use .NET polyglot notebooks for creating documentation or websites, you have to use nbconvert, which is a python tool and therefore requires the setup of a python environment.

This library aims to close that gap by

  • providing a type model for the .ipynb format (and the additional magic sauce added by .NET interactive)
  • providing an extensible interface for converting polyglot notebooks into other formats

Develop

build

Check the build project to take a look at the build targets. Here are some examples:

# Windows

# Build only
./build.cmd

# build and run tests
./build.cmd runTests

# Linux/mac

# Build only
build.sh

# build and run tests
build.sh runTests

Usage

The library is not on nuget currently, so you currently have to clone the repo and build it yourself.

Then you can use it to deserialize a notebook file like this:

open FSharp.Data.NBFormat
open System.IO

"your/path/to/a/notebook.ipynb"
|> File.ReadAllText
|> Serialiation.deserializeNotebook

nbformat.net's People

Contributors

kmutagene avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.