Python Scala Oop
Guide for translating Python classes, inheritance, and object-oriented patterns to Scala. Use when converting Python code with classes, dataclasses, abstract classes, inheritance, properties, static methods, class methods, or design patterns.
Install
npx skills add UCSB-NLP-Chang/Skill-Usage --skill python-scala-oopgit clone --depth 1 https://github.com/UCSB-NLP-Chang/Skill-Usage.git /tmp/Skill-Usage
mkdir -p ~/.claude/skills
cp -r /tmp/Skill-Usage/tasks/python-scala-translation/environment/skills/python-scala-oop ~/.claude/skills/python-scala-oopPersonal skills live in ~/.claude/skills. Use .claude/skills in a project folder to share a skill with your team.
From the SKILL.md
# Python to Scala OOP Translation
## Basic Classes
```python
# Python
class Person:
def __init__(self, name: str, age: int):
self.name = name
self.age = age
def greet(self) -> str:
return f"Hello, I'm {self.name}"
```
```scala
// Scala
class Person(val name: String, val age: Int) {
def greet: String = s"Hello, I'm $name"
}
// Usage
val person = new Person("Alice", 30) // 'new' required for class
```
## Data Classes → Case Classes
```python
# Python
from dataclasses import dataclass
@dataclass
class Point:
x: float
y: float
@dataclass(frozen=True)
class ImmutablePoint:
x: float
y: float
```
```scala
// Scala - case class is idiomatic
case class Point(x: Double, y: Double)
// Case classes are immutable by default
// They auto-generate: equals, hashCode, toString, copy, apply
// Usage
val p = Point(1.0, 2.0) // No 'new' needed for case class
val p2 = p.copy(x = 3.0) // Creates new instance with x changed
```
## Properties
```python
# Python
class Circle:
def __init__(self, radius: float):
self._radius = radius
@property
def radius(self) -> float:
return self._radius
@radius.setter
def radius(self, value: float):
if value < 0:
raise ValueError("Radius must be non-negative")
self._radius = value
@property
def area(self) -> float:
return 3.14159 * self._radius ** 2
```Details
- Skill name
python-scala-oop- Repository
- UCSB-NLP-Chang/Skill-Usage
- Path
tasks/python-scala-translation/environment/skills/python-scala-oop/SKILL.md- Repo updated
- 8 April 2026
FAQ
What does the Python Scala Oop skill do?
Guide for translating Python classes, inheritance, and object-oriented patterns to Scala. Use when converting Python code with classes, dataclasses, abstract classes, inheritance, properties, static methods, class methods, or design patterns.
How do I install the Python Scala Oop skill?
skills CLI (Claude Code, Cursor, Codex and more): npx skills add UCSB-NLP-Chang/Skill-Usage --skill python-scala-oop. Skills go in ~/.claude/skills (personal) or .claude/skills (project), and Claude loads them automatically when a task matches the description.
Is Python Scala Oop popular?
It lives in UCSB-NLP-Chang/Skill-Usage, which has 49 GitHub stars and 5 forks.
Related skills
Pubchem Database
49UCSB-NLP-Chang/Skill-Usage
Query PubChem via PUG-REST API/PubChemPy (110M+ compounds). Search by name/CID/SMILES, retrieve properties, similarity/substructure searches, bioactivity, for cheminformatics.
Pymatgen
49UCSB-NLP-Chang/Skill-Usage
Materials science toolkit. Crystal structures (CIF, POSCAR), phase diagrams, band structure, DOS, Materials Project integration, format conversion, for computational materials science.
Rdkit
49UCSB-NLP-Chang/Skill-Usage
Cheminformatics toolkit for fine-grained molecular control. SMILES/SDF parsing, descriptors (MW, LogP, TPSA), fingerprints, substructure search, 2D/3D generation, similarity, reactions. For standard workflows with simpler interface, use datamol (wrapper around RDKit). Use rdkit for advanced control, custom sanitization, specialized algorithms.
Python Scala Syntax Mapping
49UCSB-NLP-Chang/Skill-Usage
Reference guide for translating Python syntax constructs to Scala equivalents. Use when converting Python code to Scala and need mappings for basic syntax elements like variable declarations, control flow, comprehensions, string formatting, and common operators.
Python Scala Libraries
49UCSB-NLP-Chang/Skill-Usage
Guide for mapping common Python libraries and idioms to Scala equivalents. Use when converting Python code that uses standard library modules (json, datetime, os, re, logging) or needs equivalent Scala libraries for HTTP, testing, or async operations.
Restclient Migration
49UCSB-NLP-Chang/Skill-Usage
Migrate RestTemplate to RestClient in Spring Boot 3.2+. Use when replacing deprecated RestTemplate with modern fluent API, updating HTTP client code, or configuring RestClient beans. Covers GET/POST/DELETE migrations, error handling, and ParameterizedTypeReference usage.
Browse the most popular Claude skills, all software development skills, or write your own with the skills generator.